inv
message. Allows a node to advertise its knowledge of one or
more objects.
Methods
(static) decode(buf) → {DecodeResult}
Decode inv
message.
Parameters:
Name | Type | Description |
---|---|---|
buf |
Buffer | Message |
- Source:
Returns:
- Type
- DecodeResult
(static) decodePayload()
Decode inv
message payload.
The same as decode.
- Source:
(static) encode(vectors) → {Buffer}
Encode inv
message.
Parameters:
Name | Type | Description |
---|---|---|
vectors |
Array.<Buffer> | Inventory vector list |
- Source:
Returns:
Encoded message.
- Type
- Buffer
(static) encodePayload()
Encode inv
message payload.
The same as encode.
- Source:
Type Definitions
DecodeResult
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
vectors |
Array.<Buffer> | List of inventory vectors |
length |
number | Real data length |
- Source: