|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.millscript.millscript.datatypes.MapAwareTools
public final class MapAwareTools
This utility class implements list aware tools for MillScript. List aware means that these methods unify different datatypes in a list-like way. e.g. getting a specified item in a list.
These static methods provide a location to optimize Map-like operations for
particular classes. Each one provides a general fallback defined in terms
of MapFactory.make.
| Method Summary | |
|---|---|
static java.lang.Object |
get(java.lang.Object obj,
java.lang.Object key)
Returns the value for the specified key from the specified map like object. |
static void |
insert(java.lang.Object obj,
java.lang.Object key,
java.lang.Object val)
Inserts a mapping for the specified key and value into the given map like object. |
static org.millscript.commons.util.MapIterator |
mapIterator(java.lang.Object obj)
Returns a map iterator to iterate over all the entries in the specified map like object. |
static int |
size(java.lang.Object obj)
Returns the size of the specified object, seen as a map. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static java.lang.Object get(java.lang.Object obj,
java.lang.Object key)
obj - the map like object to indexkey - the key to get a value for
public static void insert(java.lang.Object obj,
java.lang.Object key,
java.lang.Object val)
obj - the map like object to insert a mapping intokey - the key to insertval - the value to associate with the keypublic static org.millscript.commons.util.MapIterator mapIterator(java.lang.Object obj)
obj - the map like object to get a map interator for
public static int size(java.lang.Object obj)
obj - the object to determine the size of
CollectionFactory
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||