getAll method
Reads the buffer starting at offset
into a byte array
.
The offset must satisy the relations 0
≤ offset
≤ this.length
.
final Buffer buf = Buffer.fromList([1, 2, 3, 4, 5, 6, 7, 8]);
print(buf); // [1, 2, 3, 4, 5, 6, 7, 8]
print(buf.getAll(2)); // [3, 4, 5, 6, 7, 8]
print(buf.getAll(4)); // [5, 6, 7, 8]
print(buf.getAll(8)); // []
Implementation
Iterable<int> getAll(
final int offset,
) {
return _data.getRange(offset, length);
}