The message to emit.
The direction that the message was sent.
Additional metadata for the message, e.g. the context.
Emit a decoded message to all listeners serially, also emits the message's children recursively.
The message to emit.
The direction that the message was sent.
Additional metadata for the message, e.g. the context.
Get all listeners for a packet.
All listeners for the packet.
The packet to get listeners for.
Remove a listener from a message.
The message to listen for.
The listener to remove.
Remove a listener from several messages being listened to.
The message to listen for.
The listener to remove.
Listen to a message being sent through the decoder.
A function to remove the listener.
The message to listen for.
The callback for when the message is decoded.
Listen to a message being sent through the decoder.
A function to remove the listener.
Listen to any of several messages being sent through the decoder.
A function to remove the listener.
The messages to listen for.
The callback for when one of the messages is decoded.
Listen to any of several messages being sent through the decoder.
A function to remove the listener.
Listen to a message being sent through the decoder once.
A function to remove the listener.
The message to listen for.
The callback for when the message is decoded.
Listen to a message being sent through the decoder once.
A function to remove the listener.
Listen to any of several messages being sent through the decoder once.
A function to remove the listener.
The messages to listen for.
The callback for when one of the messages is decoded.
Listen to any of several messages being sent through the decoder once.
A function to remove the listener.
Parse a buffer or reader in place, without emitting the resultant message.
The parsed message.
The buffer or reader to parse.
Optional
direction: MessageDirectionThe direction that the packet was sent.
Register a message or several messages to the packet decoder.
Rest
...messageClasses: Deserializable[]The packet or packets to register.
Asynchronously wait for a message to be decoded.
A promise containing the message, direciton and context metadata for the message.
The message to listen for.
Asynchronously wait for a specific message to be decoded.
A function to remove the listener.
The message to listen for.
A filter for the message to wait for.
Write a buffer or reader to the decoder.
The buffer or reader to decode.
The direction that the packet was sent.
Additional metadata for the context.
Optional
config: Partial<PacketDecoderConfig>Generated using TypeDoc
Emit a decoded message to all listeners concurrently, also emits the message's children recursively.