Package com.fasterxml.jackson.jr.ob.impl
Class DeferredMap
A specialized
Map implementation that will collect
entries during building, but only materialize full lookup structure
when needed; that is, actual building of hash lookup is deferred.
Inspired by lazily initialized Map used by Boon library.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.util.AbstractMap
putAllMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Constructor Details
-
DeferredMap
public DeferredMap(boolean ordered) -
DeferredMap
public DeferredMap(boolean ordered, int initialSize)
-
-
Method Details
-
put
-
entrySet
-
size
public int size() -
isEmpty
public boolean isEmpty() -
containsValue
- Specified by:
containsValuein interfaceMap<String,Object> - Overrides:
containsValuein classAbstractMap<String,Object>
-
containsKey
- Specified by:
containsKeyin interfaceMap<String,Object> - Overrides:
containsKeyin classAbstractMap<String,Object>
-
get
-
remove
-
clear
public void clear() -
keySet
-
values
-
equals
-
hashCode
public int hashCode() -
toString
- Overrides:
toStringin classAbstractMap<String,Object>
-
clone
- Overrides:
clonein classAbstractMap<String,Object> - Throws:
CloneNotSupportedException
-
buildIfNeeded
protected void buildIfNeeded() -
_buildMap
-