Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Optional
context: anyCalls each of the listeners registered for a given event.
Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Return an array listing the events for which the emitter has registered listeners.
Return the number of listeners listening to a given event.
Return the listeners registered for a given event.
Optional
fn: ((...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]) => void)Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Optional
context: anyOptional
once: booleanAdd a listener for a given event.
Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Optional
context: anyAdd a one-time listener for a given event.
Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Optional
context: anyRemove the listeners of a given event.
Optional
fn: ((...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]) => void)Rest
...args: ArgumentMap<SharedUdpSocketEvents>[Extract<T, keyof SharedUdpSocketEvents>]Optional
context: anyOptional
once: booleanSend a message from the shared socket
Data to send
Target port number
Target address
Optional
callback: (() => void)Callback to execute once the data has been sent
Send a message from the shared socket
Offset in the buffer to start sending from
Length of the data to send. Limited to the length of the bufer
Target port number
Target address
Optional
callback: (() => void)Callback to execute once the data has been sent
Bind to the shared socket. Until you call this, the shared socket will be inactive