Package org.apache.fop.layoutmgr
Class KnuthPossPosIter
java.lang.Object
org.apache.fop.layoutmgr.PositionIterator
org.apache.fop.layoutmgr.KnuthPossPosIter
A dedicated
PositionIterator that is backed by an iterator
over a list of KnuthElements.-
Constructor Summary
ConstructorsConstructorDescriptionKnuthPossPosIter(List elementList) Auxiliary constructorKnuthPossPosIter(List elementList, int startPos, int endPos) Main constructor -
Method Summary
Modifier and TypeMethodDescriptionprotected booleangetKE()Peek at next, returning as ListElement.protected LayoutManagerprotected PositionDefault implementation assumes that the passednextObjis itself aPosition, and just returns it.next()Methods inherited from class org.apache.fop.layoutmgr.PositionIterator
endIter, getNextChildLM, hasNext, peekNext, removeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Iterator
forEachRemaining
-
Constructor Details
-
KnuthPossPosIter
Main constructor- Parameters:
elementList- List of Knuth elementsstartPos- starting position, inclusiveendPos- ending position, exclusive
-
KnuthPossPosIter
Auxiliary constructor- Parameters:
elementList- List of Knuth elements
-
-
Method Details
-
checkNext
protected boolean checkNext()- Overrides:
checkNextin classPositionIterator- Returns:
- true if not at end of sub-sequence with same child layout manager
-
next
- Specified by:
nextin interfaceIterator<Position>- Overrides:
nextin classPositionIterator
-
getKE
Peek at next, returning as ListElement.- Returns:
- peek at next as ListElement
-
getLM
- Overrides:
getLMin classPositionIterator- Parameters:
nextObj- next object from which to obtain position- Returns:
- layout manager
-
getPos
Default implementation assumes that the passednextObjis itself aPosition, and just returns it. Subclasses for which this is not the case, must provide a suitable override this method.- Overrides:
getPosin classPositionIterator- Parameters:
nextObj- next object from which to obtain position- Returns:
- position of next object.
-