readUint8 method

int readUint8()

Reads an 8-bit unsigned integer. Increments index by 1.

Implementation

int readUint8() {
  final byteData = this._byteData;
  final index = this.index;
  final newIndex = index + 1;
  if (newIndex > byteData.lengthInBytes) {
    throw _eofException(index, "uint8");
  }
  final value = _byteData.getUint8(index);
  this.index = index + 1;
  return value;
}