Class GroupedMap<GroupedKeyType,ValueType>
java.lang.Object
tools.refinery.interpreter.rete.aggregation.GroupedMap<GroupedKeyType,ValueType>
An optimized
Map
implementation where each key is produced by joining together a group tuple and some other
object (via left inheritance). Only a select few Map
operations are supported. This collection is
unmodifiable.
Operations on this map assume that client queries also obey the contract that keys are constructed from a group tuple
and an additional object.- Since:
- 2.4
-
Nested Class Summary
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Tuple
protected final Map
<GroupedKeyType, ValueType> protected final IQueryRuntimeContext
-
Constructor Summary
ConstructorsConstructorDescriptionGroupedMap
(Tuple group, Map<GroupedKeyType, ValueType> mappings, IQueryRuntimeContext runtimeContext) -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
boolean
containsKey
(Object key) boolean
containsValue
(Object value) entrySet()
boolean
isEmpty()
keySet()
void
int
size()
values()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Field Details
-
group
-
mappings
-
runtimeContext
-
-
Constructor Details
-
GroupedMap
public GroupedMap(Tuple group, Map<GroupedKeyType, ValueType> mappings, IQueryRuntimeContext runtimeContext)
-
-
Method Details
-
size
public int size()- Specified by:
size
in interfaceMap<GroupedKeyType,
ValueType>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceMap<GroupedKeyType,
ValueType>
-
containsKey
- Specified by:
containsKey
in interfaceMap<GroupedKeyType,
ValueType>
-
containsValue
- Specified by:
containsValue
in interfaceMap<GroupedKeyType,
ValueType>
-
get
- Specified by:
get
in interfaceMap<GroupedKeyType,
ValueType>
-
put
- Specified by:
put
in interfaceMap<GroupedKeyType,
ValueType>
-
remove
- Specified by:
remove
in interfaceMap<GroupedKeyType,
ValueType>
-
putAll
- Specified by:
putAll
in interfaceMap<GroupedKeyType,
ValueType>
-
clear
public void clear()- Specified by:
clear
in interfaceMap<GroupedKeyType,
ValueType>
-
keySet
- Specified by:
keySet
in interfaceMap<GroupedKeyType,
ValueType>
-
values
- Specified by:
values
in interfaceMap<GroupedKeyType,
ValueType>
-
entrySet
- Specified by:
entrySet
in interfaceMap<GroupedKeyType,
ValueType>
-