限定符和类型 | 方法和说明 |
---|---|
java.util.Set<java.lang.String> |
getListeningPluginChannels()
获取包含了客户端正在监听的插件通道(Plugin Channel)的set集合.
|
void |
sendPluginMessage(Plugin source,
java.lang.String channel,
byte[] message)
在指定的通道向接收者发送插件消息(Plugin Message).
|
void sendPluginMessage(Plugin source, java.lang.String channel, byte[] message)
这个消息可能不大于Messenger.MAX_MESSAGE_SIZE
字节,还有插件必须注册到指定的通道上发消息.
原文:Sends this recipient a Plugin Message on the specified outgoing channel.
The message may not be larger than Messenger.MAX_MESSAGE_SIZE
bytes, and the plugin must be registered to send messages on the
specified channel.
source
- 要让插件发送的消息channel
- The channel to send this message on.在某通道上发送这个消息message
- 要发送的原始消息The raw message to send.java.lang.IllegalArgumentException
- 如果插件被禁用则抛出java.lang.IllegalArgumentException
- 如果参数source,channel或message为null则抛出MessageTooLargeException
- 如果消息过大则抛出ChannelNotRegisteredException
- 如果这个通道不是为这个插件注册的则抛出java.util.Set<java.lang.String> getListeningPluginChannels()
原文:Gets a set containing all the Plugin Channels that this client is listening on.