Package uk.gov.gchq.gaffer.mapstore
Class MapStore
- java.lang.Object
-
- uk.gov.gchq.gaffer.store.Store
-
- uk.gov.gchq.gaffer.mapstore.MapStore
-
- Direct Known Subclasses:
SingleUseMapStore
public class MapStore extends Store
An implementation ofStore
that uses any class that implements Java'sMap
interface to store theElement
s. TheElement
objects are stored in memory, i.e . no serialisation is performed.It is designed to support efficient aggregation of properties. The key of the Map is the
Element
with any group-by properties, and the value is the non-group-by properties. This allows very quick aggregation of properties from a newElement
with existing properties.Indices can optionally be maintained to allow quick look-up of
Element
s based onEntityId
s orEdgeId
s.
-
-
Field Summary
Fields Modifier and Type Field Description static Set<StoreTrait>
TRAITS
-
Constructor Summary
Constructors Constructor Description MapStore()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MapImpl
getMapImpl()
MapStoreProperties
getProperties()
Get this Store'sStoreProperties
.Set<StoreTrait>
getTraits()
Get the traits supported by this Map Store.void
initialise(String graphId, Schema schema, StoreProperties properties)
static void
resetStaticMap()
-
Methods inherited from class uk.gov.gchq.gaffer.store.Store
addOperationChainOptimisers, addOperationHandler, addOperationHandler, createContext, createStore, createStore, execute, execute, executeJob, executeJob, getCaches, getCreatedTime, getGraphId, getGraphLibrary, getJobTracker, getNextOperations, getOperationChainOptimisers, getOperationChainValidator, getOperationHandler, getOriginalSchema, getSchema, getSupportedOperations, handleOperation, isSupported, optimiseSchema, populateElement, runAsync, setGraphLibrary, setOriginalSchema, updateJsonSerialiser, updateJsonSerialiser, validateSchemas
-
-
-
-
Field Detail
-
TRAITS
public static final Set<StoreTrait> TRAITS
-
-
Method Detail
-
resetStaticMap
public static void resetStaticMap()
-
initialise
public void initialise(String graphId, Schema schema, StoreProperties properties) throws StoreException
- Overrides:
initialise
in classStore
- Throws:
StoreException
-
getMapImpl
public MapImpl getMapImpl()
-
getTraits
public Set<StoreTrait> getTraits()
Get the traits supported by this Map Store. This method is for internal Map Store use only.- Returns:
- Map Store Traits
-
getProperties
public MapStoreProperties getProperties()
Description copied from class:Store
Get this Store'sStoreProperties
.- Overrides:
getProperties
in classStore
- Returns:
- the instance of
StoreProperties
, this may contain details such as database connection details.
-
-