com.ibm.di.entry
Class PropertyMap

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.ArrayList<Property>
              extended by com.ibm.di.entry.PropertyMap
All Implemented Interfaces:
Serializable, Cloneable, Iterable<Property>, Collection<Property>, List<Property>, RandomAccess, NamedNodeMap

public class PropertyMap
extends ArrayList<Property>
implements NamedNodeMap

See Also:
Serialized Form

Field Summary
protected static String COPYRIGHT
           
 
Fields inherited from class java.util.AbstractList
modCount
 
Method Summary
 void add(int pos, Property prop)
          Adds the prop object at the specified position if its type is Property otherwise nothing is added.
 boolean add(Property prop)
          Adds the prop object if its type is Property otherwise nothing is added
 boolean addAll(Collection<? extends Property> arg0)
          Adds only the Property objects to this PropertyMap
 boolean addAll(int pos, Collection<? extends Property> colection)
          Adds only the Property objects to this PropertyMap, starting from the specified position.
 PropertyMap cloneMap(Attribute owner)
          Clones the PropertyMap and all the Property objects in it.
 int getLength()
           
 Property getNamedItem(String name)
          Looks up a Property using the specified qualified name.
 Property getNamedItemNS(String namespaceURI, String localName)
          Looks up a Property using the specified namespace URI and localName.
 Property item(int index)
           
 Property removeNamedItem(String name)
          Removes the Property referenced by the given qualified name
 Property removeNamedItemNS(String namespaceURI, String localName)
          Removes the Property referenced by the given namespace URI and localName
 Property setNamedItem(Node property)
          Adds a Property using its nodeName attribute.
 Property setNamedItemNS(Node property)
          Adds a node using its namespaceURI and localName.
 
Methods inherited from class java.util.ArrayList
clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, set, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList
 

Field Detail

COPYRIGHT

protected static final String COPYRIGHT
See Also:
Constant Field Values
Method Detail

getLength

public int getLength()
Specified by:
getLength in interface NamedNodeMap
Returns:
the number of Properties in this PropertyMap

getNamedItem

public Property getNamedItem(String name)
Looks up a Property using the specified qualified name.

Specified by:
getNamedItem in interface NamedNodeMap
Returns:
the Property that is a result of the search operation.

getNamedItemNS

public Property getNamedItemNS(String namespaceURI,
                               String localName)
                        throws DOMException
Looks up a Property using the specified namespace URI and localName.

Specified by:
getNamedItemNS in interface NamedNodeMap
Returns:
the first Property found that match the specified criterias.
Throws:
DOMException

item

public Property item(int index)
Specified by:
item in interface NamedNodeMap
Returns:
the property at the specified position

removeNamedItem

public Property removeNamedItem(String name)
                         throws DOMException
Removes the Property referenced by the given qualified name

Specified by:
removeNamedItem in interface NamedNodeMap
Returns:
the removed Property, or null if a Property with that qualified name could not be found.
Throws:
DOMException

removeNamedItemNS

public Property removeNamedItemNS(String namespaceURI,
                                  String localName)
                           throws DOMException
Removes the Property referenced by the given namespace URI and localName

Specified by:
removeNamedItemNS in interface NamedNodeMap
Returns:
the removed Property, or null if a Property with that namespace URI and localName could not be found.
Throws:
DOMException

setNamedItem

public Property setNamedItem(Node property)
                      throws DOMException
Adds a Property using its nodeName attribute. As the nodeName attribute is used to derive the name which the Property must be stored under.

Specified by:
setNamedItem in interface NamedNodeMap
Parameters:
property - A node to store in a named node map.
Returns:
If the new Property replaces an existing property the replaced Property is returned, otherwise null is returned.
Throws:
DOMException

setNamedItemNS

public Property setNamedItemNS(Node property)
                        throws DOMException
Adds a node using its namespaceURI and localName.

Specified by:
setNamedItemNS in interface NamedNodeMap
Parameters:
property - A node to store in a named node map.
Returns:
If the new Property replaces an existing Property the replaced Property is returned, otherwise null is returned.
Throws:
DOMException

cloneMap

public PropertyMap cloneMap(Attribute owner)
Clones the PropertyMap and all the Property objects in it. The new Property objects's parent references are pointed to the Attribute passed as an argument.

Parameters:
owner - - the Attribute object that will be set as the owner of the newly created Properties
Returns:
a deep clone of this PropertyMap object

add

public void add(int pos,
                Property prop)
Adds the prop object at the specified position if its type is Property otherwise nothing is added.

Specified by:
add in interface List<Property>
Overrides:
add in class ArrayList<Property>

add

public boolean add(Property prop)
Adds the prop object if its type is Property otherwise nothing is added

Specified by:
add in interface Collection<Property>
Specified by:
add in interface List<Property>
Overrides:
add in class ArrayList<Property>

addAll

public boolean addAll(Collection<? extends Property> arg0)
Adds only the Property objects to this PropertyMap

Specified by:
addAll in interface Collection<Property>
Specified by:
addAll in interface List<Property>
Overrides:
addAll in class ArrayList<Property>

addAll

public boolean addAll(int pos,
                      Collection<? extends Property> colection)
Adds only the Property objects to this PropertyMap, starting from the specified position.

Specified by:
addAll in interface List<Property>
Overrides:
addAll in class ArrayList<Property>