Package com.wavefront.agent.histogram
Class MapLoader<K,V,KM extends net.openhft.chronicle.hash.serialization.BytesReader<K> & net.openhft.chronicle.hash.serialization.BytesWriter<K>,VM extends net.openhft.chronicle.hash.serialization.SizedReader<V> & net.openhft.chronicle.hash.serialization.SizedWriter<V>>
- java.lang.Object
-
- com.wavefront.agent.histogram.MapLoader<K,V,KM,VM>
-
public class MapLoader<K,V,KM extends net.openhft.chronicle.hash.serialization.BytesReader<K> & net.openhft.chronicle.hash.serialization.BytesWriter<K>,VM extends net.openhft.chronicle.hash.serialization.SizedReader<V> & net.openhft.chronicle.hash.serialization.SizedWriter<V>> extends Object
Loader forChronicleMap
. If a file already exists at the given location, will make an attempt to load the map from the existing file. Will fall-back to an in memory representation if the file cannot be loaded (see logs).- Author:
- Tim Schmidt ([email protected]).
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description net.openhft.chronicle.map.ChronicleMap<K,V>
get(File f)
String
toString()
-
-
-
Constructor Detail
-
MapLoader
public MapLoader(Class<K> keyClass, Class<V> valueClass, long entries, double avgKeySize, double avgValueSize, KM keyMarshaller, VM valueMarshaller, boolean doPersist)
Creates a newMapLoader
- Parameters:
keyClass
- the Key classvalueClass
- the Value classentries
- the maximum number of entriesavgKeySize
- the average marshaled key size in bytesavgValueSize
- the average marshaled value size in byteskeyMarshaller
- the key codecvalueMarshaller
- the value codecdoPersist
- whether to persist the map
-
-