Objectgoog.iter.Iterator
goog.dom.TagIterator
goog.dom.RangeIterator
goog.dom.TextRangeIterator
startNode
:
The starting node position.
|
startOffset
:
The offset in to startNode. If startNode is an element, indicates an offset in to childNodes. If startNode is a text node, indicates an offset in to nodeValue.
|
endNode
:
The ending node position.
|
endOffset
:
The offset in to endNode. If endNode is an element, indicates an offset in to childNodes. If endNode is a text node, indicates an offset in to nodeValue.
|
opt_reverse
:
Whether to traverse nodes in reverse.
|
No description.
Returns:
An identical iterator.
|
code » | ||
![]()
Replace this iterator's values with values from another.
Arguments:
|
code » | ||
![]()
No description.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
No description.
|
code » | ||
Move to the next position in the selection.
Throws {@code goog.iter.StopIteration} when it passes the end of the range.
Returns:
The node at the next position.
|
code » | ||
![]()
Change the end node of the iterator.
Arguments:
|
code » | ||
![]()
Change the start node of the iterator.
Arguments:
|
code » |
No description.
Returns:
The iterator's end node.
|
code » | |
No description.
Returns:
The end offset into the current node, or -1 if the current node is not a text node.
|
code » | |
No description.
Returns:
node The iterator's start node.
|
code » | |
No description.
Returns:
The offset into the current node, or -1 if the current node is not a text node.
|
code » | |
No description.
Returns:
Whether a call to next will fail.
|
code » |
No description.
Returns:
A copy of this iterator.
|
code » | ||
![]()
Replace this iterator's values with values from another.
Arguments:
|
code » | ||
Test if two iterators are at the same position - i.e. if the node and tagType
is the same. This will still return true if the two iterators are moving in
opposite directions or have different constraints.
Arguments:
Returns:
Whether the two iterators are at the same position.
|
code » | ||
No description.
Returns:
Whether this iterator's position is an end tag position.
|
code » | ||
No description.
Returns:
Whether this iterator's position is not at an element node.
|
code » | ||
No description.
Returns:
Whether this iterator's position is a start tag position.
|
code » | ||
No description.
Returns:
Whether next has ever been called on this iterator.
|
code » | ||
Move to the next position in the DOM tree.
Returns:
Returns the next node, or throws a goog.iter.StopIteration exception if the end of the iterator's range has been reached.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
Set the position of the iterator. Overwrite the tree node and the position
type which can be one of the {@link goog.dom.TagWalkType} token types.
Only overwrites the tree depth when the parameter is specified.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
Replace the current node with the list of nodes. Reset the iterator so that
it visits the first of the nodes next.
Arguments:
|
code » |
Returns the {@code Iterator} object itself. This is used to implement
the iterator protocol in JavaScript 1.7
Arguments:
Returns:
The object itself.
|
code » | ||
![]() *
Returns the next value of the iteration. This will throw the object
{@see goog.iter#StopIteration} when the iteration passes the end.
Returns:
*
Any object or value.
|
code » |