Reply to send to the server.
Reply to send to the client.
Type used to resolve what kind of message is associated with an enum value from PeerMessageType. This allows for some extended type safety in peers.
Decode a peer message from the given buffer.
array with type of peer message followed by the data of the message
Decode a string into a binary identifier.
decoded string
Encode a peer message into a binary format.
buffer with encoded message
Encode a binary identifier to a string.
encoded string
Generate identifiers that can be used to represent nodes. These are a random UUID, generates 16 bytes of data and sets the markers used for UUID v4.
buffer with id
Helper that returns a buffer representing no identifier.
empty buffer
Check if two identifiers are the same.
true
if buffers match
Generated using TypeDoc
Classes and types related to implementing transports.