Package io.trino.plugin.base.io
Class ByteBuffers
java.lang.Object
io.trino.plugin.base.io.ByteBuffers
-
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]getBytes(ByteBuffer byteBuffer) Gets the bytes the providedByteBufferrepresents, without advancing buffer position.static byte[]getWrappedBytes(ByteBuffer byteBuffer) Gets the bytes the providedByteBufferwraps, without advancing buffer position.
-
Method Details
-
getWrappedBytes
Gets the bytes the providedByteBufferwraps, without advancing buffer position. Throws when provided buffer does not directly wrap bytes. -
getBytes
Gets the bytes the providedByteBufferrepresents, without advancing buffer position. The returned byte array may be shared with the buffer.
-