length property

int get length

The length of the ByteArray object, in bytes.

Implementation

int get length {
  return _bytes.length;
}
set length (int value)

The length of the ByteArray object, in bytes.

Implementation

set length(int value) {
  if (_position > value) {
    _position = value;
  }
  if (_bytes.length != value) {
    _bytes.length = value;
    _dataDirty = true;
  }
}