|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.AbstractMap
org.biojava.utils.OverlayMap
public class OverlayMap
Overlap one map onto another. This allows you to have a map with local values and default values. The local and default values are provided by a child and parent map.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface java.util.Map |
|---|
Map.Entry |
| Constructor Summary | |
|---|---|
OverlayMap(Map parent)
Build a new map with default key-value pairs. |
|
OverlayMap(Map parent,
Map overlay)
Build a new map with default key-value pairs. |
|
| Method Summary | |
|---|---|
boolean |
containsKey(Object key)
|
Set |
entrySet()
|
Object |
get(Object key)
|
Map |
getOverlayMap()
Return the object containing the overlay mappings. |
Map |
getParentMap()
Return the object containing the fallback mappings. |
Set |
keySet()
|
Object |
put(Object key,
Object value)
|
| Methods inherited from class java.util.AbstractMap |
|---|
clear, clone, containsValue, equals, hashCode, isEmpty, putAll, remove, size, toString, values |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public OverlayMap(Map parent,
Map overlay)
parent - the default fall-through Mapoverlay - the overriding Mappublic OverlayMap(Map parent)
parent - the default fall-through Map| Method Detail |
|---|
public Map getParentMap()
public Map getOverlayMap()
public Object get(Object key)
get in interface Mapget in class AbstractMappublic Set entrySet()
entrySet in interface MapentrySet in class AbstractMappublic Set keySet()
keySet in interface MapkeySet in class AbstractMappublic boolean containsKey(Object key)
containsKey in interface MapcontainsKey in class AbstractMap
public Object put(Object key,
Object value)
put in interface Mapput in class AbstractMap
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||