Add Buffer.put implementation.

This commit is contained in:
Andy Nguyen 2021-11-06 17:57:15 +01:00
parent 3347cbb544
commit 05adae5e31

View File

@ -79,6 +79,11 @@ public class Buffer {
api.write64(address + offset, value);
}
public void put(int offset, Buffer buffer) {
checkOffset(offset, buffer.size());
api.memcpy(address + offset, buffer.address(), buffer.size());
}
public void fill(byte value) {
api.memset(address, value, size);
}