Class NativeEndianMemoryUtil
java.lang.Object
org.apache.cassandra.utils.memory.MemoryUtil
org.apache.cassandra.utils.memory.NativeEndianMemoryUtil
Use this API only for data which are stored in-memory
and not serialized directly (without converting to Java primitives) to disk and network
-
Field Summary
Fields inherited from class org.apache.cassandra.utils.memory.MemoryUtil
BYTE_BUFFER_CLASS, unsafe -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ByteBuffergetByteBuffer(long address, int length) static ByteBufferstatic intgetInt(long address) static longgetLong(long address) static intgetUnsignedShort(long address) static voidsetInt(long address, int l) static voidsetLong(long address, long l) static voidsetShort(long address, short s) Methods inherited from class org.apache.cassandra.utils.memory.MemoryUtil
allocate, duplicateDirectByteBuffer, free, getAddress, getAttachment, getByte, getByteBuffer, getBytes, getHollowDirectByteBuffer, isExactlyDirect, pageSize, setAttachment, setByte, setByte, setByteBufferCapacity, setBytes, setBytes, setBytes, setBytes, setDirectByteBuffer, sliceDirectByteBuffer
-
Constructor Details
-
NativeEndianMemoryUtil
public NativeEndianMemoryUtil()
-
-
Method Details
-
getUnsignedShort
public static int getUnsignedShort(long address) -
getInt
public static int getInt(long address) -
getLong
public static long getLong(long address) -
setShort
public static void setShort(long address, short s) -
setInt
public static void setInt(long address, int l) -
setLong
public static void setLong(long address, long l) -
getByteBuffer
-
getHollowDirectByteBuffer
-