public class LongDataType extends BasicDataType<Long>
| 限定符和类型 | 字段和说明 |
|---|---|
static LongDataType |
INSTANCE |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
binarySearch(Long keyObj,
Object storageObj,
int size,
int initialGuess)
Perform binary search for the key within the storage
|
int |
compare(Long one,
Long two)
Compare two keys.
|
Long[] |
createStorage(int size)
Create storage object of array type to hold values
|
int |
getMemory(Long obj)
Calculates the amount of used memory in bytes.
|
Long |
read(ByteBuffer buff)
Read an object.
|
void |
write(WriteBuffer buff,
Long data)
Write an object.
|
cast, equals, hashCode, isMemoryEstimationAllowed, read, writepublic static final LongDataType INSTANCE
public int getMemory(Long obj)
DataTypepublic void write(WriteBuffer buff, Long data)
DataTypepublic Long read(ByteBuffer buff)
DataTypepublic Long[] createStorage(int size)
DataTypesize - number of values to holdpublic int compare(Long one, Long two)
DataTypecompare 在接口中 Comparator<Long>compare 在接口中 DataType<Long>compare 在类中 BasicDataType<Long>one - the first keytwo - the second keypublic int binarySearch(Long keyObj, Object storageObj, int size, int initialGuess)
DataTypebinarySearch 在接口中 DataType<Long>binarySearch 在类中 BasicDataType<Long>keyObj - to search forstorageObj - to search within (an array of type T)size - number of data items in the storageinitialGuess - for key positionCopyright © 2022. All rights reserved.