Class AbstractHistoricalNavigableMap<K,V,M extends java.util.NavigableMap<K,V>>
- java.lang.Object
-
- org.opentrafficsim.core.perception.AbstractHistorical<K,AbstractHistoricalMap.EventMap<K,V,M>>
-
- org.opentrafficsim.core.perception.collections.AbstractHistoricalMap<K,V,M>
-
- org.opentrafficsim.core.perception.collections.AbstractHistoricalSortedMap<K,V,M>
-
- org.opentrafficsim.core.perception.collections.AbstractHistoricalNavigableMap<K,V,M>
-
- Type Parameters:
K- key typeV- value typeM- navigable map type
- All Implemented Interfaces:
java.util.Map<K,V>,java.util.NavigableMap<K,V>,java.util.SortedMap<K,V>,HistoricalMap<K,V>,HistoricalNavigableMap<K,V>,HistoricalSortedMap<K,V>,HistoryManager.HistoricalElement
- Direct Known Subclasses:
HistoricalTreeMap
public abstract class AbstractHistoricalNavigableMap<K,V,M extends java.util.NavigableMap<K,V>> extends AbstractHistoricalSortedMap<K,V,M> implements HistoricalNavigableMap<K,V>
NavigableMap-valued historical state. The current navigable map is always maintained, and past states of the navigable map are obtained by applying the events between now and the requested time in reverse.
The set views and sub-maps returned by this class are unmodifiable.Copyright (c) 2013-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version 2 feb. 2018
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.opentrafficsim.core.perception.collections.AbstractHistoricalMap
AbstractHistoricalMap.EventMap<K,V,M extends java.util.Map<K,V>>
-
Nested classes/interfaces inherited from class org.opentrafficsim.core.perception.AbstractHistorical
AbstractHistorical.EventValue<T>
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractHistoricalNavigableMap(HistoryManager historyManager, M map)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map.Entry<K,V>ceilingEntry(K key)KceilingKey(K key)java.util.NavigableSet<K>descendingKeySet()java.util.NavigableMap<K,V>descendingMap()java.util.Map.Entry<K,V>firstEntry()java.util.Map.Entry<K,V>floorEntry(K key)KfloorKey(K key)java.util.NavigableMap<K,V>headMap(K toKey, boolean inclusive)java.util.Map.Entry<K,V>higherEntry(K key)KhigherKey(K key)java.util.Map.Entry<K,V>lastEntry()java.util.Map.Entry<K,V>lowerEntry(K key)KlowerKey(K key)java.util.NavigableSet<K>navigableKeySet()java.util.Map.Entry<K,V>pollFirstEntry()java.util.Map.Entry<K,V>pollLastEntry()java.util.NavigableMap<K,V>subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)java.util.NavigableMap<K,V>tailMap(K fromKey, boolean inclusive)-
Methods inherited from class org.opentrafficsim.core.perception.collections.AbstractHistoricalSortedMap
comparator, firstKey, headMap, lastKey, subMap, tailMap
-
Methods inherited from class org.opentrafficsim.core.perception.collections.AbstractHistoricalMap
clear, containsKey, containsValue, entrySet, fill, fill, get, getMap, isEmpty, keySet, put, putAll, remove, size, values
-
Methods inherited from class org.opentrafficsim.core.perception.AbstractHistorical
addEvent, cleanUpHistory, getEvent, getEvents, getLastEvent, isLastState, now, removeEvent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.opentrafficsim.core.perception.collections.HistoricalMap
replaceAll
-
Methods inherited from interface org.opentrafficsim.core.perception.collections.HistoricalNavigableMap
get, get
-
-
-
-
Constructor Detail
-
AbstractHistoricalNavigableMap
protected AbstractHistoricalNavigableMap(HistoryManager historyManager, M map)
Constructor.- Parameters:
historyManager- HistoryManager; history managermap- M; initial map
-
-
Method Detail
-
navigableKeySet
public java.util.NavigableSet<K> navigableKeySet()
-
descendingKeySet
public java.util.NavigableSet<K> descendingKeySet()
-
subMap
public java.util.NavigableMap<K,V> subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)
-
-