DOMUtil.NodeListImpl (Apache Ant API)
Description: declaration: package: org.apache.tools.ant.taskdefs.optional.junit, class: DOMUtil, class: NodeListImpl

# Class DOMUtil.NodeListImpl

java.lang.Object
java.util.AbstractCollection<Node>
java.util.AbstractList<Node>
java.util.Vector<Node>
org.apache.tools.ant.taskdefs.optional.junit.DOMUtil.NodeListImpl

All Implemented Interfaces:
  `Serializable, Cloneable, Iterable<Node>, Collection<Node>, List<Node>, RandomAccess, SequencedCollection<Node>, NodeList`

Enclosing class:
  `DOMUtil`

public static class DOMUtil.NodeListImpl extends Vector<Node> implements NodeList
custom implementation of a nodelist

See Also:
  - Serialized Form

- ## Field Summary

  ### Fields inherited from class Vector

  `capacityIncrement, elementCount, elementData`

  ### Fields inherited from class AbstractList

  `modCount`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `NodeListImpl()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getLength()`
  Get the number of nodes in the list.
  `Node`
  `item(int i)`
  Get a particular node.

  ### Methods inherited from class Vector

  `add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, forEach, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, iterator, lastElement, lastIndexOf, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeIf, removeRange, replaceAll, retainAll, set, setElementAt, setSize, size, sort, spliterator, subList, toArray, toArray, toString, trimToSize`

  ### Methods inherited from class Object

  `finalize, getClass, notify, notifyAll, wait, wait, wait`

  ### Methods inherited from interface Collection

  `parallelStream, stream, toArray`

  ### Methods inherited from interface List

  `addFirst, addLast, getFirst, getLast, removeFirst, removeLast, reversed`

- ## Constructor Details

  - ### NodeListImpl

    public NodeListImpl()

- ## Method Details

  - ### getLength

    public int getLength()
    Get the number of nodes in the list.
    Specified by:
      `getLength` in interface `NodeList`
    Returns:
      the length of the list.

  - ### item

    public Node item(int i)
    Get a particular node.
    Specified by:
      `item` in interface `NodeList`
    Parameters:
      `i` - the index of the node to get.
    Returns:
      the node if the index is in bounds, null otherwise.