If an existing HierarchicalMap is specified, a shallow copy is made.
Optional
existing: HierarchicalMap<Key, Value, Parent>Existing map to make a shallow copy of.
Private
parentRegister parent
as a parent map. If priority > 0
, this map will take precedence over
direct bindings.
A nullary function that unregisters the parent (and may be called at most once).
Find all values to which the specified key is mapped.
Generated using TypeDoc
Maps string event identifiers to string action identifiers.
When an event identifier is looked up in a given HierarchicalMap, it is resolved to a corresponding action identifier in one of two ways:
via mappings defined directly on the HierarchicalMap.
via a recursive lookup on a "parent" HierarchicalMap that has been specified for the root HierarchicalMap on which the lookup was initiated.
HierarchicalMap objects may be specified as "parents" of another HierarchicalMap along with a specified numerical priority value, such that there is a directed graph of HierarchicalMap objects. Cycles in this graph may lead to infinite looping.
Recursive lookups in parent HierarchicalMap objects are performed in order of decreasing priority. The lookup stops as soon as a mapping is found. Direct bindings have a priority of 0. Therefore, parent maps with a priority higher than 0 take precedence over direct bindings.