Sets the environment to accept a given type and identifier of message. Parameters can be replaced with "nil" to act as a wildcard.
Usage:
Command.Message.Accept(type, identifier) |
Parameter | Type | Datatype | Description |
identifier | parameter | string/nil | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
type | parameter | string/nil | The type of message. Valid types include "tell", "channel", "guild", "officer", "party", "raid", "say", "yell", "send". |
Broadcast an unreliable addon message to some number of targets. This message will be dropped silently if the targets do not have the available bandwidth to receive it. The callback will respond with failure only if the message's target is invalid. "tell" messages are subject to the same restrictions as Command.Message.Send(). This command is throttled by the "message" throttle type.
Usage:
Command.Message.Broadcast(type, target, identifier, data) |
Command.Message.Broadcast(type, target, identifier, data, callback) |
Parameter | Type | Datatype | Description |
callback | parameter | callbackfunction | A standard command callback, used for detecting success or failure. See the "callbackfunction" documentation for more details. |
data | parameter | string | The data to send. This parameter is binary-safe. |
identifier | parameter | string | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
target | parameter | string/nil | The target of this message. Required for "channel" or "tell" message types, must be nil otherwise. |
type | parameter | string | The type of message to send. Valid types include "tell", "channel", "guild", "officer", "party", "raid", "say", "yell". |
Sets the environment to reject a given type and identifier of message. Directly cancels out single calls to Command.Message.Accept.
Usage:
Command.Message.Reject(type, identifier) |
Parameter | Type | Datatype | Description |
identifier | parameter | string/nil | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
type | parameter | string/nil | The type of message. Valid types include "tell", "channel", "guild", "officer", "party", "raid", "say", "yell", "send". |
Send an reliable addon message to a single target. The callback will respond with success only once the server has accepted the message for processing and queueing. Failure may occur if the target is invalid or if the target's receive queue is full. Messages may be sent only to players that are nearby, in your guild, in your party or raid, or that have sent you a message or tell during this session. This command is throttled by the "message" throttle type.
Usage:
Command.Message.Send(target, identifier, data, callback) |
Parameter | Type | Datatype | Description |
callback | parameter | callbackfunction | A standard command callback, used for detecting success or failure. See the "callbackfunction" documentation for more details. |
data | parameter | string | The data to send. This parameter is binary-safe. |
identifier | parameter | string | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
target | parameter | string | The name of the player to send the message to. |
Signals the receipt of an addon message.
Usage:
Event.Message.Receive(from, type, channel, identifier, data) |
Parameter | Type | Datatype | Description |
channel | parameter | <nope> | If type is "channel", the channel that this message was sent to. Otherwise, nil. |
data | parameter | <nope> | The data payload for this message type. |
from | parameter | variant | The name of the player this message is from. |
identifier | parameter | <nope> | The identifier for this message. |
type | parameter | <nope> | The type of this message. May be any of "send", "tell", "channel", "guild", "officer", "party", "raid", "say", or "yell". |
Checks whether a given message type would be accepted if it were sent to you. Parameters can be replaced by "nil" to check for wildcard acceptance.
Usage:
accepted = Inspect.Message.Accept.Check(type, identifier) |
Parameter | Type | Datatype | Description |
identifier | parameter | string/nil | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
type | parameter | string/nil | The type of message. Valid types include "tell", "channel", "guild", "officer", "party", "raid", "say", "yell", "send". |
accepted | result | boolean | True if the message would be transferred to this client. |
Retrieves the list of accepted message types and identifiers.
Usage:
accepts = Inspect.Message.Accept.List() |
Parameter | Type | Datatype | Description |
accepts | result | table | List of all accepted message types. Takes the form of a key/value table. The key is a table containing {type, identifier}, where either element may be nil to indicate a wildcard. The value is the number of times this type has been accepted. |
Returns information on the message bandwidth limits.
Usage:
data = Utility.Message.Limits() |
Parameter | Type | Datatype | Description |
data | result | table | The requested data. |
- members
-
burst |
The amount of data that can be sent or received without being subject to throttling.
|
maximum |
Maximum allowed message size.
|
sustained |
Amount of data that can be transferred per second without dropping messages.
|
Returns the size of a message, as used for bandwidth control.
Usage:
size = Utility.Message.Size(to, identifier, data) |
Parameter | Type | Datatype | Description |
data | parameter | string | The data to send. This parameter is binary-safe. |
identifier | parameter | string | The identifier type of the message. Used for the receiver to filter accepted messages via the Command.Message.Accept() function. Must be at least three characters long. |
to | parameter | string/nil | The name of the player or channel to send to. nil if this is not targeted at a specific player or channel. |
size | result | number | The calculated size of the message. |