Namespace: var_int_list

bitmessage/structs. var_int_list

Methods

(static) decode(buf) → {DecodeResult}

Decode var_int_list.
NOTE: rest references input buffer.

Parameters:
Name Type Description
buf Buffer

A buffer that starts with encoded var_int_list

Source:
Returns:
Type
DecodeResult

(static) encode(list) → {Buffer}

Encode list of numbers into var_int_list.

Parameters:
Name Type Description
list Array.<number>

A number list

Source:
Returns:

Encoded var_int_list.

Type
Buffer

Type Definitions

DecodeResult

Type:
  • Object
Properties:
Name Type Description
list number

Stored numbers

length number

var_int_list full length

rest Buffer

The rest of the input buffer

Source: