cz.cuni.amis.pogamut.usar2004.agent.module.datatypes
Class GeometryContainer
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<String,Map<String,SuperGeometry>>
cz.cuni.amis.pogamut.usar2004.agent.module.datatypes.GeometryContainer
- All Implemented Interfaces:
- Serializable, Cloneable, Map<String,Map<String,SuperGeometry>>
public class GeometryContainer
- extends HashMap<String,Map<String,SuperGeometry>>
Container of geometry message representatives. It is basicly a hashmap of
maps. There is geometry messages logged by type and than by name.
- Author:
- vejmanm
- See Also:
- Serialized Form
| Methods inherited from class java.util.HashMap |
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values |
GeometryContainer
public GeometryContainer()
getGeometriesByType
public List<SuperGeometry> getGeometriesByType(String type)
- Gets geometry message representatives from local hashmap. Returns null if
none matches or this hash map is empty.
- Parameters:
type - String representing the type of Geometry to return
- Returns:
- Returns List of specified type of Geometry representatives.
getGeometriesByGeometryType
public List<SuperGeometry> getGeometriesByGeometryType(GeometryType type)
- Iterates through local hashmap values and seeks match. Returns null if
this hash map is empty. Note, that if type = UNKNOWN_Geometry it
returns all unknown Geometries.
- Parameters:
type - GeometryType representing the type of Geometry to return
- Returns:
- Returns List of all Geometries that suit input GeometryType.
getGeometriesByClass
public List<SuperGeometry> getGeometriesByClass(Class c)
- Adds every object that can be casted to initial class to the output list.
Note that if You feed this method with SuperClass it will return all
available submodules.
- Parameters:
c - Class representing the type of which the return list should be
- Returns:
- Returns a list of eligible objects, that can be casted to Class c
getGeometryByTypeName
public SuperGeometry getGeometryByTypeName(String type,
String name)
- Gets geometry message representatives from local hashmap specified by
type and by name. Returns null if none matches or this hash map is empty.
- Parameters:
type - String representing the type of geometry to return.name - String representing the name of geometry to return.
- Returns:
- Returns List of specified type of Geometry representative.
getNonEmptyDescription
public List<MessageDescriptor> getNonEmptyDescription()
- For each type of Geometry it adds all individuals to the returnee List as
a couple (Type, Name)
- Returns:
- returns Map of couples (Type/Name) of non empty Geometries
Copyright © 2014 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.