|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--torero.model.AttributeMap
The AttributeMap is a collection used for creation and lookup of Attributes for a specific grammar. It ensures the uniqueness of the Attributes defined in it.
Constructor Summary | |
AttributeMap()
|
Method Summary | |
boolean |
contains(String attribname)
Returns true if an Attribute or Traversal with that name exists. |
Collection |
getAttributes()
Returns all Attributes in this AttributeMap as Collection. |
Collection |
getAttributesAndTraversals()
Returns all Attributes and Traversals in this AttributeMap as Collection. |
int |
getAttributeSize()
Returns the number of Attributes and Traversals in this AttributeMap. |
Collection |
getTraversals()
Returns all Traversals in this AttributeMap as Collection. |
Attribute |
obtainAttribute(String name)
If an Attribute with the given name already exists its given back - otherwhise a new one is created and given back. |
Traversal |
obtainTraversal(String name)
If a Traversal with the given name already exists its given back - otherwhise a new one is created and given back. |
void |
removeAttribute(Attribute attribute)
This method removes the given Attribute from the AttributeMap. |
protected void |
updateEntry(Attribute attrib,
String oldname)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AttributeMap()
Method Detail |
public Attribute obtainAttribute(String name)
name
- takes the Name of the Attribute that should be obtained.public Traversal obtainTraversal(String name)
name
- takes the Name of the Traversal that should be obtained.public boolean contains(String attribname)
protected void updateEntry(Attribute attrib, String oldname)
public int getAttributeSize()
public Collection getAttributesAndTraversals()
public Collection getAttributes()
public Collection getTraversals()
public void removeAttribute(Attribute attribute)
attribute
- takes the Attribute to remove from the AttributeMap
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |