Package net.cscott.jutil
Class AggregateMapFactory<K,V>
java.lang.Object
net.cscott.jutil.AggregateMapFactory<K,V>
- All Implemented Interfaces:
Serializable,MapFactory<K,V>
AggregateMapFactory uses a single HashMap
as backing store for the many smaller Maps created
by this MapFactory. This means that we use much
less space and rehash less frequently than if we were using
the standard Factories.hashMapFactory().
The iterators of the submaps are fast, unlike those of
HashMap.- Author:
- C. Scott Ananian <cananian@alumni.princeton.edu>
- See Also:
-
Constructor Details
-
AggregateMapFactory
public AggregateMapFactory()Creates anAggregateMapFactory.
-
-
Method Details
-
makeMap
Generates a new mutableMapwhich is a subset of the backing set of thisAggregateMapFactory.- Specified by:
makeMapin interfaceMapFactory<K,V>
-