Skip to main content

Class: ProtobufJsonPayloadConverter

protobufs.ProtobufJsonPayloadConverter

Converts between protobufjs Message instances and serialized JSON Payload

Hierarchy

  • ProtobufPayloadConverter

    ProtobufJsonPayloadConverter

Constructors

constructor

new ProtobufJsonPayloadConverter(root?): ProtobufJsonPayloadConverter

Parameters

NameTypeDescription
root?unknownThe value returned from patchProtobufRoot

Returns

ProtobufJsonPayloadConverter

Overrides

ProtobufPayloadConverter.constructor

Properties

encodingType

encodingType: "json/protobuf"

Overrides

ProtobufPayloadConverter.encodingType

Methods

fromPayload

fromPayload<T>(content): T

Type parameters

Name
T

Parameters

NameType
contentIPayload

Returns

T

Overrides

ProtobufPayloadConverter.fromPayload


toPayload

toPayload(value): undefined | IPayload

Parameters

NameType
valueunknown

Returns

undefined | IPayload

Overrides

ProtobufPayloadConverter.toPayload