Class DocumentElementImpl
- All Implemented Interfaces:
DocumentElement,Serializable
- Direct Known Subclasses:
ElementImpl,FrameImpl,FrameImpl,GroupImpl,ParagraphImpl,PlaceholderImpl
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintgetId()Gets the Id of this element.doubleGets the size of this element.Gets the size of this element.doubleGets the visible size of this element.Gets the visible size of this element.voidsetId(int id) Sets the Id of the element.voidsetSizeAbsolute(double sizeAbsolute) Sets the size of this element.voidsetSizeRelative(String sizeRelative) Sets the size of this element.voidsetVisibleSizeAbsolute(double visibleSizeAbsolute) Sets the visible size of this element.voidsetVisibleSizeRelative(String visibleSizeRelative) Sets the visible size of this element.
-
Constructor Details
-
DocumentElementImpl
public DocumentElementImpl()
-
-
Method Details
-
getId
public int getId()Description copied from interface:DocumentElementGets the Id of this element.
Gets the Id of this element.
This Id is guaranteed to be unique within a particular document. Unless the document content changes, the Id is also guaranteed to be persistent.
For certain element types (such asGroup), the Id is also guaranteed to be persistent as long as a (semantically) identical element exists in the document.- Specified by:
getIdin interfaceDocumentElement- Returns:
- the Id of this element
-
setId
public void setId(int id) Description copied from interface:DocumentElementSets the Id of the element.
Sets the Id of this element. For further information see
DocumentElement.getId()- Specified by:
setIdin interfaceDocumentElement- Parameters:
id- Id of the element
-
getVisibleSizeRelative
Description copied from interface:DocumentElementGets the visible size of this element.
Gets the visible size relative to the page (not the spread!) size of this element.
Calculation of the size is based on the area of the element, which is not covered, overlapped or whatsoever by any other element on that page.- Specified by:
getVisibleSizeRelativein interfaceDocumentElement- Returns:
- relative visible size of this element
-
setVisibleSizeRelative
Description copied from interface:DocumentElementSets the visible size of this element.
Sets the visible size of this element. For further information see
DocumentElement.getVisibleSizeRelative()- Specified by:
setVisibleSizeRelativein interfaceDocumentElement- Parameters:
visibleSizeRelative- relative visible size of this element
-
getVisibleSizeAbsolute
public double getVisibleSizeAbsolute()Description copied from interface:DocumentElementGets the visible size of this element.
Gets the absolute visible size of this element.
As all absolute size specifications are based on pt, the size is given in "squarepoints". Calculation of the size is based on the area of the element, which is not covered, overlapped or whatsoever by any other element on that page.- Specified by:
getVisibleSizeAbsolutein interfaceDocumentElement- Returns:
- absolute visible size of this element
-
setVisibleSizeAbsolute
public void setVisibleSizeAbsolute(double visibleSizeAbsolute) Description copied from interface:DocumentElementSets the visible size of this element.
Sets the visible size of this element. For further information see
DocumentElement.getVisibleSizeAbsolute()- Specified by:
setVisibleSizeAbsolutein interfaceDocumentElement- Parameters:
visibleSizeAbsolute- absolute visible size of this element
-
getSizeRelative
Description copied from interface:DocumentElementGets the size of this element.
Gets the size relative to the page (not the spread!) size of this element.
Calculation of the size is based on the entire area covered by this element.- Specified by:
getSizeRelativein interfaceDocumentElement- Returns:
- relative size of this element
-
setSizeRelative
Description copied from interface:DocumentElementSets the size of this element.
Sets the size of this element. For further information see
DocumentElement.getSizeRelative()- Specified by:
setSizeRelativein interfaceDocumentElement- Parameters:
sizeRelative- relative size of this element
-
getSizeAbsolute
public double getSizeAbsolute()Description copied from interface:DocumentElementGets the size of this element.
Gets the absolute size of this element.
As all absolute size specifications are based on pt, the size is given in "squarepoints". Calculation of the size is based on the entire area covered by this element.- Specified by:
getSizeAbsolutein interfaceDocumentElement- Returns:
- absolute size of this element
-
setSizeAbsolute
public void setSizeAbsolute(double sizeAbsolute) Description copied from interface:DocumentElementSets the size of this element.
Sets the size of this element. For further information see
DocumentElement.getSizeAbsolute()- Specified by:
setSizeAbsolutein interfaceDocumentElement- Parameters:
sizeAbsolute- absolute size of this element
-