Class FSTBinaryOffheapMap

java.lang.Object
org.nustaq.offheap.FSTBinaryOffheapMap
Direct Known Subclasses:
FSTCodedOffheapMap

public class FSTBinaryOffheapMap
extends java.lang.Object
Baseclass of offheap maps. FST OffHeap Maps enable to store key/value pairs in offheap memory. Additionally it provides and iterator interface for all values. In order to also iterate keys, add each key to its value object, as this OffHeap map does not support iteration of keys out of the box. See subclasses for directly applicable classes (E.g. FSTStringOffheapMap) The base is a generic bytesource to bytesource map. Note that key should be as short as possible (4-20 bytes) and should have their most modified digit at the last character of their value. e.g. [0,0,0,0,123,44] where '44' changes with each new key. Else on-heap memory consumption will grow. Performance of lookup degrades with growing key size. In case entries are updated frequently with values of different size, avoid fragementation by adding extra space to each entry. Override getEntryLengthForContentLength for this.