Class LeafFactoryVariableBytes
java.lang.Object
com.semedy.reasoner.edb.persistentstore.bplustree.LeafFactoryVariableBytes
- All Implemented Interfaces:
LeafFactory<byte[],
ByteBuffer>
-
Constructor Summary
ConstructorDescriptionLeafFactoryVariableBytes
(int nodeSize, KeysFactoryVariableBytes keysFactory) -
Method Summary
Modifier and TypeMethodDescriptionBPlusLeaf<byte[],
ByteBuffer> createLeaf
(byte[] bytes, BPlusTree<byte[], ByteBuffer> bplustree) Method for creating a leaf from the given byte array.BPlusLeaf<byte[],
ByteBuffer> createLeaf
(BPlusKeys<byte[], ByteBuffer> keys, long[] records, BPlusTree<byte[], ByteBuffer> bplustree) create a new leaf with given records and the offset to the left nodeBPlusLeaf<byte[],
ByteBuffer> createLeaf
(BPlusKeys<byte[], ByteBuffer> keys, BPlusTree<byte[], ByteBuffer> bplustree) create new leafsint
get the size of a bplus node in number of bytes
-
Constructor Details
-
LeafFactoryVariableBytes
-
-
Method Details
-
getNodeSize
public int getNodeSize()Description copied from interface:LeafFactory
get the size of a bplus node in number of bytes- Specified by:
getNodeSize
in interfaceLeafFactory<byte[],
ByteBuffer> - Returns:
-
createLeaf
public BPlusLeaf<byte[],ByteBuffer> createLeaf(BPlusKeys<byte[], ByteBuffer> keys, BPlusTree<byte[], ByteBuffer> bplustree) create new leafs- Specified by:
createLeaf
in interfaceLeafFactory<byte[],
ByteBuffer> - Parameters:
keys
-bplustree
-- Returns:
-
createLeaf
public BPlusLeaf<byte[],ByteBuffer> createLeaf(BPlusKeys<byte[], ByteBuffer> keys, long[] records, BPlusTree<byte[], ByteBuffer> bplustree) Description copied from interface:LeafFactory
create a new leaf with given records and the offset to the left node- Specified by:
createLeaf
in interfaceLeafFactory<byte[],
ByteBuffer> - Returns:
-
createLeaf
public BPlusLeaf<byte[],ByteBuffer> createLeaf(byte[] bytes, BPlusTree<byte[], ByteBuffer> bplustree) Method for creating a leaf from the given byte array.- Specified by:
createLeaf
in interfaceLeafFactory<byte[],
ByteBuffer> - Parameters:
bytes
-- Returns:
-