@NotNull @Override public HeapBytesStore<Underlying> writeShort(long offset, short i16) throws BufferOverflowException { writeCheckOffset(offset, 2); MEMORY.writeShort(realUnderlyingObject, dataOffset + offset, i16); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeVolatileShort(long offset, short i16) throws BufferOverflowException { writeCheckOffset(offset, 2); MEMORY.writeVolatileShort(realUnderlyingObject, dataOffset + offset, i16); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeLong(long offset, long i64) throws BufferOverflowException { writeCheckOffset(offset, 8); MEMORY.writeLong(realUnderlyingObject, dataOffset + offset, i64); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeDouble(long offset, double d) throws BufferOverflowException { writeCheckOffset(offset, 8); MEMORY.writeDouble(realUnderlyingObject, dataOffset + offset, d); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeVolatileByte(long offset, byte i8) throws BufferOverflowException { writeCheckOffset(offset, 1); MEMORY.writeVolatileByte(realUnderlyingObject, dataOffset + offset, i8); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeVolatileLong(long offset, long i64) throws BufferOverflowException { writeCheckOffset(offset, 8); MEMORY.writeVolatileLong(realUnderlyingObject, dataOffset + offset, i64); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeInt(long offset, int i32) throws BufferOverflowException { writeCheckOffset(offset, 4); MEMORY.writeInt(realUnderlyingObject, dataOffset + offset, i32); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeOrderedLong(long offset, long i) throws BufferOverflowException { writeCheckOffset(offset, 8); MEMORY.writeOrderedLong(realUnderlyingObject, dataOffset + offset, i); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeByte(long offset, byte b) throws BufferOverflowException { writeCheckOffset(offset, 1); MEMORY.writeByte(realUnderlyingObject, dataOffset + offset, b); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeOrderedInt(long offset, int i32) throws BufferOverflowException { writeCheckOffset(offset, 4); MEMORY.writeOrderedInt(realUnderlyingObject, dataOffset + offset, i32); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeFloat(long offset, float f) throws BufferOverflowException { writeCheckOffset(offset, 4); MEMORY.writeFloat(realUnderlyingObject, dataOffset + offset, f); return this; }
@NotNull @Override public HeapBytesStore<Underlying> writeVolatileInt(long offset, int i32) throws BufferOverflowException { writeCheckOffset(offset, 4); MEMORY.writeVolatileInt(realUnderlyingObject, dataOffset + offset, i32); return this; }
@NotNull @Override public HeapBytesStore<Underlying> write( long offsetInRDO, byte[] bytes, int offset, int length) throws BufferOverflowException { writeCheckOffset(offsetInRDO, length); MEMORY.copyMemory( bytes, offset, realUnderlyingObject, this.dataOffset + offsetInRDO, length); return this; }
@Override public void write( long offsetInRDO, @NotNull ByteBuffer bytes, int offset, int length) throws BufferOverflowException { writeCheckOffset(offsetInRDO, length); assert realUnderlyingObject == null || dataOffset >= (Jvm.is64bit() ? 12 : 8); if (bytes.isDirect()) { MEMORY.copyMemory(((DirectBuffer) bytes).address(), realUnderlyingObject, this.dataOffset + offsetInRDO, length); } else { MEMORY.copyMemory(bytes.array(), offset, realUnderlyingObject, this.dataOffset + offsetInRDO, length); } }