DirectPipe class

Implemented types
Mixed-in types

Constructors

DirectPipe(MagLink _link)

Properties

className → String
Class name shown by toString: the actual runtime type when asserts are enabled (debug builds), or the fixed 'DirectPipe' otherwise.
no setter
hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

decodePayload(Uint8List payload) → Map
inherited
encodePayload(Map info) → Uint8List
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
padPayload(Map<Object?, Object?> body, {required Config config}) → Uint8List
Pad the JSON body to at least Config.handshakeMinPayload bytes with a 'blah' field (docs/client.md section 5.1): the value repeats 'blah' separated by spaces, so the padded body may exceed the minimum by up to 4 bytes.
inherited
processPacket(Packet packet) → void
Handle one packet forwarded by the link: the default implementations answer "PONG" to heartbeats (echoing the payload with 'time' refreshed, docs/client.md section 6) and "COPY" to data packets (sn/index paired, docs/client.md section 4.2, section 9).
override
sendData(Uint8List payload, {required int sn, int index = 0, int count = 1}) → bool
Build a data packet (A=0, D=1, sn/index/count for the reliability layer) and send it through the link.
override
sendPacket(Magpie packet) → bool
Pack and send the datagram through the link: it is signed with the session secret when bound, and deferred while the handshake is still in progress.
override
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited