Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| fop 2.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.fop.area
Class Page

    java.lang.Object
      org.apache.fop.area.AreaTreeObject
          org.apache.fop.area.Page

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable

    public class Page

extends AreaTreeObject
implements java.io.Serializable

The page. This holds the contents of the page. Each region is added. The unresolved references area added so that if the page is serialized then it will handle the resolving properly after being reloaded. This is serializable so it can be saved to cache to save memory if there are forward references. The page is cloneable so the page master can make copies of the top level page and regions.

See Also:
  Serialized Form

Field Summary

Fields inherited from class org.apache.fop.area.AreaTreeObject
`extensionAttachments, foreignAttributes`

Constructor Summary
`Page()` Empty constructor
`Page(SimplePageMaster spm)` Constructor

Method Summary
`java.lang.Object` | `clone()`
`void` | `fakeNonEmpty()` Call this method to force this page to pretend not to be empty.
`RegionViewport` | `getRegionViewport(int areaClass)` Get the region from this page.
`java.util.Map<java.lang.String,java.util.List<Resolvable>>` | `getUnresolvedReferences()` Get the map unresolved references from this page.
`boolean` | `isEmpty()` Indicates whether any FOs have been added to the body region
`void` | `setRegionViewport(int areaclass, RegionViewport port)` Set the region on this page.
`void` | `setUnresolvedReferences(java.util.Map<java.lang.String,java.util.List<Resolvable>> unres)` Set the unresolved references on this page for serializing.
`void` | `setWritingModeTraits(WritingModeTraitsGetter wmtg)` Sets the writing mode traits for the region viewports of this page.

Methods inherited from class org.apache.fop.area.AreaTreeObject
`addExtensionAttachment, getExtensionAttachments, getForeignAttributes, getForeignAttributeValue, hasExtensionAttachments, setExtensionAttachments, setForeignAttribute, setForeignAttributes`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Page

    public Page()

  Empty constructor

### Page

    public Page(SimplePageMaster spm)

  Constructor

  Parameters:
    `spm` - SimplePageMaster containing the dimensions for this page-reference-area

Method Detail

### fakeNonEmpty

    public void fakeNonEmpty()

  Call this method to force this page to pretend not to be empty.

### setRegionViewport

    public void setRegionViewport(int areaclass,
                                  RegionViewport port)

  Set the region on this page.

  Parameters:
    `areaclass` - the area class of the region to set
    `port` - the region viewport to set

### getRegionViewport

    public RegionViewport getRegionViewport(int areaClass)

  Get the region from this page.

  Parameters:
    `areaClass` - the region area class
  Returns:
    the region viewport or null if none

### isEmpty

    public boolean isEmpty()

  Indicates whether any FOs have been added to the body region

  Returns:
    whether any FOs have been added to the body region

### clone

    public java.lang.Object clone()
                           throws java.lang.CloneNotSupportedException

  Overrides:
    `clone` in class `AreaTreeObject`
  Throws:
    `java.lang.CloneNotSupportedException`

### setUnresolvedReferences

    public void setUnresolvedReferences(java.util.Map<java.lang.String,java.util.List<Resolvable>> unres)

  Set the unresolved references on this page for serializing.

  Parameters:
    `unres` - the Map of unresolved objects

### getUnresolvedReferences

    public java.util.Map<java.lang.String,java.util.List<Resolvable>> getUnresolvedReferences()

  Get the map unresolved references from this page. This should be called after deserializing to retrieve the map of unresolved references that were serialized.

  Returns:
    the de-serialized HashMap of unresolved objects

### setWritingModeTraits

    public void setWritingModeTraits(WritingModeTraitsGetter wmtg)

  Sets the writing mode traits for the region viewports of this page.

  Parameters:
    `wmtg` - a WM traits getter

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| fop 2.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 1999-2016 The Apache Software Foundation. All Rights Reserved.