writeUint16 method
Write a 16-bit word to the output stream.
Implementation
void writeUint16(int value) {
if (byteOrder == ByteOrder.bigEndian) {
writeByte((value >> 8) & 0xff);
writeByte(value & 0xff);
} else {
writeByte(value & 0xff);
writeByte((value >> 8) & 0xff);
}
}