public interface Messenger
Channels.| Modifier and Type | Method and Description |
|---|---|
default <T> Channel<T> |
getChannel(String name,
Class<T> clazz)
Gets a channel by name.
|
<T> Channel<T> |
getChannel(String name,
TypeToken<T> type)
Gets a channel by name.
|
default <T extends ConversationMessage,R extends ConversationMessage> |
getConversationChannel(String name,
Class<T> clazz,
Class<R> replyClazz)
Gets a conversation channel by name.
|
default <T extends ConversationMessage,R extends ConversationMessage> |
getConversationChannel(String name,
TypeToken<T> type,
TypeToken<R> replyType)
Gets a conversation channel by name.
|
@Nonnull <T> Channel<T> getChannel(@Nonnull String name, @Nonnull TypeToken<T> type)
T - the channel message typename - the name of the channel.type - the channel message typetoken@Nonnull default <T extends ConversationMessage,R extends ConversationMessage> ConversationChannel<T,R> getConversationChannel(@Nonnull String name, @Nonnull TypeToken<T> type, @Nonnull TypeToken<R> replyType)
T - the channel message typeR - the channel reply typename - the name of the channeltype - the channel outgoing message typetokenreplyType - the channel incoming (reply) message typetoken@Nonnull default <T> Channel<T> getChannel(@Nonnull String name, @Nonnull Class<T> clazz)
T - the channel message typename - the name of the channel.clazz - the channel message class@Nonnull default <T extends ConversationMessage,R extends ConversationMessage> ConversationChannel<T,R> getConversationChannel(@Nonnull String name, @Nonnull Class<T> clazz, @Nonnull Class<R> replyClazz)
T - the channel message typeR - the channel reply typename - the name of the channelclazz - the channel outgoing message classreplyClazz - the channel incoming (reply) message classCopyright © 2020. All rights reserved.