javax.xml.crypto.dom
Class DOMNodeSetData

java.lang.Object
  extended byjavax.xml.crypto.dom.DOMNodeSetData
All Implemented Interfaces:
Data, NodeSetData

public class DOMNodeSetData
extends java.lang.Object
implements NodeSetData

A DOM-specific NodeSetData. The purpose of this class is to provide additional context necessary for iterating over DOM node sets.

The iterators returned by this class are live. This means that advancing or changing the position of a returned iterator affects all other iterators returned by this class.

Unless otherwise specified, the methods defined in this class are not thread-safe. Multiple threads that need to access a single object concurrently should synchronize amongst themselves and provide the necessary locking. Multiple threads each manipulating separate objects need not synchronize.


Constructor Summary
DOMNodeSetData(org.w3c.dom.traversal.NodeIterator ni)
          Creates a DOMNodeSetData containing the specified NodeIterator.
 
Method Summary
 java.util.Iterator iterator()
          Returns a read-only iterator over the nodes contained in this NodeSetData.
 org.w3c.dom.traversal.NodeIterator nodeIterator()
          Returns a NodeIterator over the nodes contained in this DOMNodeSetData.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DOMNodeSetData

public DOMNodeSetData(org.w3c.dom.traversal.NodeIterator ni)
Creates a DOMNodeSetData containing the specified NodeIterator.

Parameters:
ni - the NodeIterator
Throws:
java.lang.NullPointerException - if ni is null
Method Detail

nodeIterator

public org.w3c.dom.traversal.NodeIterator nodeIterator()
Returns a NodeIterator over the nodes contained in this DOMNodeSetData.

Returns:
a NodeIterator over the nodes in this DOMNodeSetData

iterator

public java.util.Iterator iterator()
Description copied from interface: NodeSetData
Returns a read-only iterator over the nodes contained in this NodeSetData. Attempts to modify the returned iterator via the remove method throw UnsupportedOperationException.

Specified by:
iterator in interface NodeSetData
Returns:
an Iterator over the nodes in this NodeSetData