SourceForge.net Logo
aXSL API 0.1

org.axsl.areaW
Interface PageCollection

All Superinterfaces:
AreaNode, FOContext, OrderedTreeNode, javax.swing.tree.TreeNode

public interface PageCollection
extends AreaNode

A PageCollection is a collection of formatted pages. It is the immediate child of AreaTree, and the parent of one or more Pages.


Method Summary
 int getCurrentPageNumber()
          Returns the page number currently being processed.
 PageArea getNextPage(boolean forceOdd, boolean forceEven, boolean isBlank)
          Creates a new page area for the given parameters.
 int getPageCount()
          Returns the current count of pages in this collection.
 PageSequence getPageSequence()
          Returns the generating PageSequence.
 AreaTree getWritableAreaTree()
          Returns the parent AreaTree.
 void padPagesAtBeginning()
          Creates any blank pages that are needed at the beginning of a PageCollection to meet the related PageSequence's constraints.
 void padPagesAtEnd()
          Creates any blank pages that are needed at the end of a PageCollection to meet the related PageSequence's constraints.
 SpanRA startingReferenceArea(FObj lastFObj, FObj nextFObj)
          Finds or creates the SpanRA instance in which nextFObj should start being laid out.
 
Methods inherited from interface org.axsl.areaW.AreaNode
ancestorTableArea, ancestorWritableNormalBlockArea, crBPDNearestGeneratedByBlockLevelFO, crIPDNearestGeneratedByBlockLevelFO, getFontConsumer, getTextServer, getWritablePage, getWritableParent, getWritableParentArea, nearestGeneratedByBlockLevelFO, removeChild, traitGeneratedBy
 
Methods inherited from interface org.axsl.common.OrderedTreeNode
getChildren, getFirstChild, getFirstLeaf, getLastChild, getLastLeaf, getNextLeaf, getNextSibling, getPreviousLeaf, getPreviousSibling, getSiblings, hasChildren, nextPreOrderNode, siblingIndex
 
Methods inherited from interface javax.swing.tree.TreeNode
children, getAllowsChildren, getChildAt, getChildCount, getIndex, getParent, isLeaf
 
Methods inherited from interface org.axsl.foR.FOContext
getRetrieveMarker
 

Method Detail

getWritableAreaTree

public AreaTree getWritableAreaTree()
Returns the parent AreaTree.

Returns:
The parent AreaTree.

getPageSequence

public PageSequence getPageSequence()
Returns the generating PageSequence.

Returns:
The generating PageSequence.

padPagesAtBeginning

public void padPagesAtBeginning()
                         throws AreaWException
Creates any blank pages that are needed at the beginning of a PageCollection to meet the related PageSequence's constraints.

Throws:
AreaWException - For errors in padding pages.

padPagesAtEnd

public void padPagesAtEnd()
                   throws AreaWException
Creates any blank pages that are needed at the end of a PageCollection to meet the related PageSequence's constraints.

Throws:
AreaWException - For errors in padding pages.

getCurrentPageNumber

public int getCurrentPageNumber()
Returns the page number currently being processed.

Returns:
The raw page number currently being processed.

getNextPage

public PageArea getNextPage(boolean forceOdd,
                            boolean forceEven,
                            boolean isBlank)
                     throws AreaWException
Creates a new page area for the given parameters.

Parameters:
forceOdd - Set to true to force the next page to be an odd page.
forceEven - Set to true to force the next page to be an even page.
isBlank - True iff this page will be empty (e.g. forced even or odd break, or forced page count).
Returns:
A Page layout object based on the page master selected from the params.
Throws:
AreaWException - For errors in creating new page.

getPageCount

public int getPageCount()
Returns the current count of pages in this collection.

Returns:
The count of pages in this collection.

startingReferenceArea

public SpanRA startingReferenceArea(FObj lastFObj,
                                    FObj nextFObj)
                             throws AreaWException
Finds or creates the SpanRA instance in which nextFObj should start being laid out.

Parameters:
lastFObj - The last FObj that was laid out, null if nextFObj is the first one for this page-sequence.
nextFObj - The FObj for which we are trying to find the staring Area for layout.
Returns:
The ColumnRA instance into which nextFObj should be laid out.
Throws:
AreaWException - For errors creating the appropriate Areas.

SourceForge.net Logo
aXSL API 0.1

This documentation was created September 6 2006 by The aXSL Group and may be freely copied. See license for details.