public class BasicPage extends AbstractPage
listenerSupport
PROPERTY_PREFIX_USER_PROPERTY
Constructor and Description |
---|
BasicPage()
Construct a new
Page and attach it to the given Document . |
Modifier and Type | Method and Description |
---|---|
void |
add(DocumentLayer layer,
PageSegment pageSegment)
Adds given page segment at given
DocumentLayer . |
DocumentLayer |
getDocumentLayer(PageSegment segment)
Retrieve the
DocumentLayer for a given AbstractPageSegment |
Set<DocumentLayer> |
getLayers()
Return the
DocumentLayer s for which this page has a page segment. |
PageSegment |
getPageSegment(DocumentLayer layer)
Retrieve the
PresentationElement at a given DocumentLayer |
Collection<PageSegment> |
getPageSegments()
Return the
PageSegment s this page holds. |
Map<DocumentLayer,PageSegment> |
getSegmentMap()
Return the map of
DocumentLayer s to PageSegment s. |
Dimension2D |
getSize()
Get the raw size of the page in base units.
|
void |
remove(DocumentLayer layer)
Removes the page segment at the given
DocumentLayer . |
String |
toString() |
addPageListener, getModCount, getProperties, removePageListener
public BasicPage()
Page
and attach it to the given Document
.public PageSegment getPageSegment(DocumentLayer layer)
PresentationElement
at a given DocumentLayer
layer
- the layer for which to extract the page segment.PresentationElement
or null
if there is no page segment at the
specified layer.public DocumentLayer getDocumentLayer(PageSegment segment)
DocumentLayer
for a given AbstractPageSegment
segment
- the page segment for which to extract the layer.DocumentLayer
or null
if there is no layer for the specified
page segment.public void add(DocumentLayer layer, PageSegment pageSegment)
DocumentLayer
.layer
- the layer at which to add the segment.pageSegment
- the page segment to addpublic void remove(DocumentLayer layer)
DocumentLayer
.layer
- the layer at which to add the segment.public Dimension2D getSize()
public Set<DocumentLayer> getLayers()
DocumentLayer
s for which this page has a page segment.public Collection<PageSegment> getPageSegments()
PageSegment
s this page holds.public String toString()
toString
in class Object
Object.toString()
public Map<DocumentLayer,PageSegment> getSegmentMap()
Page
DocumentLayer
s to PageSegment
s. Depending on the
implementation of this interface, the returned map may be "live" or read-only.getSegmentMap
in interface Page
getSegmentMap
in class AbstractPage
DocumentLayer
s to PageSegment
s.Copyright © 2024 levigo holding gmbh. All rights reserved.