Namespace: types

types

Common type constants.

Members

types.basic constant{ Object<string, number> }

Basic type wire types.

Properties:
Name Type Default Description
double number 1

Fixed64 wire type

float number 5

Fixed32 wire type

int32 number 0

Varint wire type

uint32 number 0

Varint wire type

sint32 number 0

Varint wire type

fixed32 number 5

Fixed32 wire type

sfixed32 number 5

Fixed32 wire type

int64 number 0

Varint wire type

uint64 number 0

Varint wire type

sint64 number 0

Varint wire type

fixed64 number 1

Fixed64 wire type

sfixed64 number 1

Fixed64 wire type

bool number 0

Varint wire type

string number 2

Ldelim wire type

bytes number 2

Ldelim wire type

types.defaults constant{ Object<string, *> }

Basic type defaults.

Properties:
Name Type Default Description
double number 0

Double default

float number 0

Float default

int32 number 0

Int32 default

uint32 number 0

Uint32 default

sint32 number 0

Sint32 default

fixed32 number 0

Fixed32 default

sfixed32 number 0

Sfixed32 default

int64 number 0

Int64 default

uint64 number 0

Uint64 default

sint64 number 0

Sint32 default

fixed64 number 0

Fixed64 default

sfixed64 number 0

Sfixed64 default

bool boolean false

Bool default

string string ""

String default

bytes Array.<number> Array(0)

Bytes default

message null null

Message default

types.long constant{ Object<string, number> }

Basic long type wire types.

Properties:
Name Type Default Description
int64 number 0

Varint wire type

uint64 number 0

Varint wire type

sint64 number 0

Varint wire type

fixed64 number 1

Fixed64 wire type

sfixed64 number 1

Fixed64 wire type

types.mapKey constant{ Object<string, number> }

Allowed types for map keys with their associated wire type.

Properties:
Name Type Default Description
int32 number 0

Varint wire type

uint32 number 0

Varint wire type

sint32 number 0

Varint wire type

fixed32 number 5

Fixed32 wire type

sfixed32 number 5

Fixed32 wire type

int64 number 0

Varint wire type

uint64 number 0

Varint wire type

sint64 number 0

Varint wire type

fixed64 number 1

Fixed64 wire type

sfixed64 number 1

Fixed64 wire type

bool number 0

Varint wire type

string number 2

Ldelim wire type

types.packed constant{ Object<string, number> }

Allowed types for packed repeated fields with their associated wire type.

Properties:
Name Type Default Description
double number 1

Fixed64 wire type

float number 5

Fixed32 wire type

int32 number 0

Varint wire type

uint32 number 0

Varint wire type

sint32 number 0

Varint wire type

fixed32 number 5

Fixed32 wire type

sfixed32 number 5

Fixed32 wire type

int64 number 0

Varint wire type

uint64 number 0

Varint wire type

sint64 number 0

Varint wire type

fixed64 number 1

Fixed64 wire type

sfixed64 number 1

Fixed64 wire type

bool number 0

Varint wire type