CodedBufferWriter class

Writer used for converting GeneratedMessages into binary representation.

Note that it is impossible to serialize protobuf messages using a one pass streaming serialization as some values are serialized using length-delimited representation, which means that they are represented as a varint encoded length followed by specified number of bytes of data.

Due to this CodedBufferWritter maintains two output buffers: _outputChunks which contains all continuously written bytes and _splices which describes additional bytes to splice in-between _outputChunks bytes.




hashCode int
The hash code for this object. [...]
read-only, inherited
lengthInBytes int
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited


noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
toBuffer() Uint8List
toString() String
A string representation of this object. [...]
writeField(int fieldNumber, int fieldType, dynamic fieldValue) → void
writeInt32NoTag(int value) → void
writeRawBytes(TypedData value) → void
Add TypedData splice - these bytes would be directly copied into the output buffer by writeTo.
writeTo(Uint8List buffer, [int offset = 0]) bool
Serializes everything written to this writer so far to buffer, starting from offset in buffer. Returns true on success.


operator ==(Object other) bool
The equality operator. [...]