WriteBuffer class

Write-only buffer for incrementally building a ByteData instance.

A WriteBuffer instance can be used only once. Attempts to reuse will result in NoSuchMethodErrors being thrown.

The byte order used is Endian.host throughout.

Constructors

WriteBuffer()
Creates an interface for incrementally building a ByteData instance.

Properties

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

Methods

done() ByteData
Finalize and return the written ByteData.
putFloat64(double value) → void
Write an Float64 into the buffer.
putFloat64List(Float64List list) → void
Write all the values from a Float64List into the buffer.
putInt32(int value) → void
Write an Int32 into the buffer.
putInt32List(Int32List list) → void
Write all the values from an Int32List into the buffer.
putInt64(int value) → void
Write an Int64 into the buffer.
putInt64List(Int64List list) → void
Write all the values from an Int64List into the buffer.
putUint8(int byte) → void
Write a Uint8 into the buffer.
putUint8List(Uint8List list) → void
Write all the values from a Uint8List into the buffer.
putUint16(int value) → void
Write a Uint16 into the buffer.
putUint32(int value) → void
Write a Uint32 into the buffer.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited