public interface MessageChannelEvent extends MessageEvent
Text
message and MessageChannel
s.Modifier and Type | Interface and Description |
---|---|
static interface |
MessageChannelEvent.Chat
Fired when the
Text being sent to a MessageChannel was
due to chatting. |
MessageEvent.DefaultBodyApplier, MessageEvent.DefaultHeaderApplier, MessageEvent.MessageFormatter
PARAM_MESSAGE_BODY, PARAM_MESSAGE_FOOTER, PARAM_MESSAGE_HEADER
Modifier and Type | Method and Description |
---|---|
Optional<MessageChannel> |
getChannel()
Gets the current channel that this message will be sent to.
|
MessageChannel |
getOriginalChannel()
Gets the original channel that this message will be sent to.
|
void |
setChannel(MessageChannel channel)
Sets the channel for this message to go to.
|
clearMessage, getFormatter, getMessage, getOriginalMessage, isMessageCancelled, setMessage, setMessage, setMessage, setMessageCancelled
getCause, getContext, getSource
MessageChannel getOriginalChannel()
Optional<MessageChannel> getChannel()
Note that an Optional.empty()
channel is different from a
MessageChannel.TO_NONE
channel.
void setChannel(@Nullable MessageChannel channel)
Note that setting this to null
, or no channel, is different
from a MessageChannel.TO_NONE
channel.
channel
- The channel to set