public class NodeListImpl
extends java.util.ArrayList
implements org.w3c.dom.NodeList
org.w3c.dom.NodeList interface, representing a non-live view of the DOM.
Note: Methods in this class are not synchronized.
| Constructor and Description | 
|---|
NodeListImpl()
Creates a new, empty  
NodeListImpl. | 
NodeListImpl(java.util.Collection nodes)
Creates a new  
NodeListImpl containing the given Collection's Nodes. | 
NodeListImpl(int size)
Creates a new, empty  
NodeListImpl with the given initial capacity. | 
NodeListImpl(org.w3c.dom.Node node)
Creates a new  
NodeListImpl containing the given Node. | 
NodeListImpl(org.w3c.dom.NodeList nodes)
Creates a new  
NodeListImpl containing the given NodeList's Nodes. | 
| Modifier and Type | Method and Description | 
|---|---|
int | 
getLength()
Returns the number of nodes in the list. 
 | 
org.w3c.dom.Node | 
item(int index)
Returns the  
indexth item in the collection. | 
java.lang.String | 
toString()
Returns a string representation of this node list. 
 | 
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeRange, retainAll, set, size, subList, toArray, toArray, trimToSizepublic NodeListImpl()
NodeListImpl.public NodeListImpl(int size)
NodeListImpl with the given initial capacity.size - The initial capacity for the new NodeListImpl.java.lang.IllegalArgumentException - If size is less than 0.public NodeListImpl(org.w3c.dom.Node node)
NodeListImpl containing the given Node.node - The node to be contained in the new NodeListImpl.public NodeListImpl(org.w3c.dom.NodeList nodes)
NodeListImpl containing the given NodeList's Nodes.nodes - The nodes to be contained in the new NodeListImpl.public NodeListImpl(java.util.Collection nodes)
NodeListImpl containing the given Collection's Nodes.nodes - The nodes to be contained in the new NodeListImpl.public java.lang.String toString()
toString in class java.util.AbstractCollectionpublic org.w3c.dom.Node item(int index)
indexth item in the collection. If index is greater than or equal to the number of nodes in the list, this returns null.item in interface org.w3c.dom.NodeListindex - Index into the collection.indexth position in the NodeList, or null if that is not a valid index.public int getLength()
length-1 inclusive.getLength in interface org.w3c.dom.NodeList