|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.levigo.jadice.document.AbstractPage com.levigo.jadice.document.BasicPage
public class BasicPage
Represents a page of a Document
.
The Page
provides additional page specific information of a document. This may be
ModelElement
s, containing the actual representation of the document, like annotations or
document content or some page specific metadata.
Field Summary |
---|
Fields inherited from class com.levigo.jadice.document.AbstractPage |
---|
listenerSupport |
Fields inherited from interface com.levigo.jadice.document.Page |
---|
PROPERTY_PREFIX_USER_PROPERTY |
Constructor Summary | |
---|---|
BasicPage()
Construct a new Page and attach it to the given Document . |
Method Summary | |
---|---|
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 ModelElement 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()
|
Methods inherited from class com.levigo.jadice.document.AbstractPage |
---|
addPageListener, getModCount, getProperties, removePageListener |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public BasicPage()
Page
and attach it to the given Document
.
Method Detail |
---|
public PageSegment getPageSegment(DocumentLayer layer)
ModelElement
at a given DocumentLayer
layer
- the layer for which to extract the page segment.
ModelElement
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.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |