|
Search this API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object y.io.graphml.DictionaryLookup
public final class DictionaryLookup
A simple mutable Lookup
implementation that
is backed by a Map
.
Constructor Summary | |
---|---|
DictionaryLookup()
Creates an instance with an initially empty map as backing store. |
|
DictionaryLookup(Map map)
Creates an instance with the given map as the backing store. |
Method Summary | |
---|---|
boolean |
hasLookup(Class type)
Determines whether the specified type exists in this lookup. |
Object |
lookup(Class type)
Performs the lookup |
void |
put(Class type,
Object value)
Adds an in instance to the map for the given type. |
void |
remove(Class type)
Removes the specified type from this lookup. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DictionaryLookup()
public DictionaryLookup(Map map)
IllegalArgumentException
- if the map
is null
map
- the backing store.Method Detail |
---|
public void put(Class type, Object value)
If value
is null
the entry is removed
from the map.
IllegalArgumentException
- if the parameters do not matchtype
- the type that will be used as a key for queriesvalue
- the instance implementing type
or null
public Object lookup(Class type)
lookup
in interface Lookup
type
- the type to query
null
public boolean hasLookup(Class type)
type
- The type to look up.
true
if the specified type exists in this lookup;
false
otherwise.public void remove(Class type)
type
- The type to remove from this instance.
|
© Copyright 2000-2013, yWorks GmbH. All rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |