Package org.apache.fop.fo
Interface FONode.FONodeIterator
-
- All Known Implementing Classes:
FObj.FObjIterator
- Enclosing class:
- FONode
public static interface FONode.FONodeIterator extends java.util.ListIterator<FONode>
Base iterator interface over a FO's children, offering three methods on top of the base interface methods.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidadd(FONode newNode)Add the givennewNodeat the current position.FONodefirst()Returns the first node in the list, and decreases the index, so that a subsequent call tohasPrevious()will returnfalsebooleanhasNext()booleanhasPrevious()FONodelast()Returns the last node in the list, and advances the current position, so that a subsequent call tohasNext()will returnfalseFONodenext()intnextIndex()FObjparent()Returns the parent node for this iterator's list of child nodesFONodeprevious()intpreviousIndex()voidremove()Removes the node at the current position.voidset(FONode newNode)Replace the node at the current index with the givennewNode.
-
-
-
Method Detail
-
next
FONode next()
-
previous
FONode previous()
- Specified by:
previousin interfacejava.util.ListIterator<FONode>- Returns:
- the previous node
-
set
void set(FONode newNode)
Replace the node at the current index with the givennewNode.- Specified by:
setin interfacejava.util.ListIterator<FONode>- Parameters:
newNode- the new node
-
add
void add(FONode newNode)
Add the givennewNodeat the current position.- Specified by:
addin interfacejava.util.ListIterator<FONode>- Parameters:
newNode- the new node
-
hasNext
boolean hasNext()
-
hasPrevious
boolean hasPrevious()
- Specified by:
hasPreviousin interfacejava.util.ListIterator<FONode>- Returns:
trueif there is a previous node,falseotherwise
-
nextIndex
int nextIndex()
- Specified by:
nextIndexin interfacejava.util.ListIterator<FONode>- Returns:
- the current index
-
previousIndex
int previousIndex()
- Specified by:
previousIndexin interfacejava.util.ListIterator<FONode>- Returns:
- the previous index
-
remove
void remove()
Removes the node at the current position.
-
parent
FObj parent()
Returns the parent node for this iterator's list of child nodes- Returns:
- the parent node
-
first
FONode first()
Returns the first node in the list, and decreases the index, so that a subsequent call tohasPrevious()will returnfalse- Returns:
- the first node in the list
-
last
FONode last()
Returns the last node in the list, and advances the current position, so that a subsequent call tohasNext()will returnfalse- Returns:
- the last node in the list
-
-