org.apache.pivot.xml
Class Element.ElementDictionary

java.lang.Object
  extended by org.apache.pivot.xml.Element.ElementDictionary
All Implemented Interfaces:
Dictionary<String,String>
Enclosing class:
Element

public class Element.ElementDictionary
extends Object
implements Dictionary<String,String>

Dictionary representing the attributes declared by this element.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.pivot.collections.Dictionary
Dictionary.Pair<K,V>
 
Method Summary
 boolean containsKey(String attributeName)
          Tests for the existence of an attribute.
 String get(String attributeName)
          Returns an attribute value.
 String put(String attributeName, String value)
          Sets an attribute value.
 String remove(String attributeName)
          Removes an attribute.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

get

public String get(String attributeName)
Returns an attribute value.

Specified by:
get in interface Dictionary<String,String>
Parameters:
attributeName -
Returns:
The value associated with the given attribute, or null

put

public String put(String attributeName,
                  String value)
Sets an attribute value.

Specified by:
put in interface Dictionary<String,String>
Parameters:
attributeName -
value -
Returns:
The value previously associated with the given attribute, or null if the attribute did not previously exist.

remove

public String remove(String attributeName)
Removes an attribute.

Specified by:
remove in interface Dictionary<String,String>
Parameters:
attributeName -
Returns:
The value previously associated with the given attribute.

containsKey

public boolean containsKey(String attributeName)
Tests for the existence of an attribute.

Specified by:
containsKey in interface Dictionary<String,String>
Parameters:
attributeName -
Returns:
true if this element defines the given attribute; false, otherwise.