NodeIterator Interface

Table 2-19 summarizes the methods available through NodeIterator interface.

Table 2-19 Summary of NodeIterator Methods; Dom Package

Function Summary

adjustCtx()

Attach this iterator to the another context.

detach()

Invalidate the iterator.

nextNode()

Go to the next node.

previousNode()

Go to the previous node.



adjustCtx()

Attaches this iterator to the context associated with a given node reference

Syntax

void adjustCtx( 
   NodeRef< Node>& nref);
Parameter Description
nref
reference node


detach()

Invalidates the iterator.

Syntax

void detach();

nextNode()

Go to the next node.

Syntax

Node* nextNode() throw (DOMException);

Returns

(Node*) pointer to the next node


previousNode()

Go to the previous node.

Syntax

Node* previousNode() throw (DOMException);

Returns

(Node*) pointer to the previous node