writeBytes method

int writeBytes(
  1. List<int> bs
)

Writes a list of bytes.

Implementation

int writeBytes(List<int> bs) {
  if (_bitsBufferLength == 0) {
    _bytesBuffer.writeAll(bs);
    return 1;
  }

  final length = bs.length;
  for (var i = 0; i < length; ++i) {
    writeByte(bs[i]);
  }

  return length;
}