public class AnnotObject extends Object
Constructor and Description |
---|
AnnotObject() |
Modifier and Type | Method and Description |
---|---|
void |
addAttribute(AttributeObject attr)
Adds new AttributeObject to the list of annotation attributes.
|
ActionObject |
getAction()
Gets Action element, a child of OnActivation element of the link annotation.
|
String |
getAppearance()
Gets the string value of the appearance element, a child element of stamp element.
|
AttributeObject |
getAttribute(String name)
Finds the attribute by name in attributes list.
|
List<AttributeObject> |
getAttributes()
Gets a list of all attributes of the annotation.
|
String |
getAttributeValue(String name)
Finds the attribute by name in attributes list and return its string value.
|
BorderStyleAltObject |
getBorderStyleAlt()
Gets the BorderStyleAlt element, a child of the link element.
|
PdfString |
getContents()
Gets the string value of contents tag in Xfdf document structure.
|
PdfString |
getContentsRichText()
Gets the string value of contents-richtext tag in Xfdf document structure.
|
String |
getDefaultAppearance()
Gets the string value of the defaultappearance element, a child of the caret and freetext elements.
|
String |
getDefaultStyle()
Gets the string value of the defaultstyle element, a child of the freetext element.
|
DestObject |
getDestination()
Gets Dest element, a child element of link, GoTo, GoToR elements.
|
String |
getName()
Gets the string value of the type of annotation.
|
AnnotObject |
getPopup()
Gets the popup annotation, an inner element of the annotation element.
|
PdfIndirectReference |
getRef()
Gets the reference to the source PdfAnnotation .
|
String |
getVertices()
Gets the string, containing vertices element, a child of the polygon and polyline elements.
|
boolean |
isHasPopup()
Gets the boolean, indicating if annotation has inner popup element.
|
AnnotObject |
setAction(ActionObject action)
Sets Action element, a child of OnActivation element of the link annotation.
|
AnnotObject |
setAppearance(String appearance)
Gets the string value of the appearance element, a child element of stamp element.
|
AnnotObject |
setBorderStyleAlt(BorderStyleAltObject borderStyleAlt)
Sets the BorderStyleAlt element, a child of the link element.
|
AnnotObject |
setContents(PdfString contents)
Sets the string value of contents tag in Xfdf document structure.
|
AnnotObject |
setContentsRichText(PdfString contentsRichRext)
Gets the string value of contents-richtext tag in xfdf document structure.
|
AnnotObject |
setDefaultAppearance(String defaultAppearance)
Sets the string value of the defaultappearance element, a child of the caret and freetext elements.
|
AnnotObject |
setDefaultStyle(String defaultStyle)
Sets the string value of the defaultstyle element, a child of the freetext element.
|
AnnotObject |
setDestination(DestObject destination)
Sets Dest element, a child element of link, GoTo, GoToR elements.
|
AnnotObject |
setHasPopup(boolean hasPopup)
Sets the boolean, indicating if annotation has inner popup element.
|
AnnotObject |
setName(String name)
Sets the string value of the type of annotation.
|
AnnotObject |
setPopup(AnnotObject popup)
Sets the popup annotation, an inner element of the annotation element.
|
AnnotObject |
setRef(PdfIndirectReference ref)
Sets the reference to the source PdfAnnotation .
|
AnnotObject |
setVertices(String vertices)
Sets the string, containing vertices element, a child of the polygon and polyline elements.
|
public String getName()
XfdfConstants.CARET
, XfdfConstants.CIRCLE
, XfdfConstants.FILEATTACHMENT
, XfdfConstants.FREETEXT
, XfdfConstants.HIGHLIGHT
, XfdfConstants.INK
, XfdfConstants.LINE
, XfdfConstants.POLYGON
, XfdfConstants.POLYLINE
, XfdfConstants.SOUND
, XfdfConstants.SQUARE
, XfdfConstants.SQUIGGLY
, XfdfConstants.STAMP
, XfdfConstants.STRIKEOUT
, XfdfConstants.TEXT
, XfdfConstants.UNDERLINE
.
public AnnotObject setName(String name)
XfdfConstants.CARET
, XfdfConstants.CIRCLE
, XfdfConstants.FILEATTACHMENT
, XfdfConstants.FREETEXT
, XfdfConstants.HIGHLIGHT
, XfdfConstants.INK
, XfdfConstants.LINE
, XfdfConstants.POLYGON
, XfdfConstants.POLYLINE
, XfdfConstants.SOUND
, XfdfConstants.SQUARE
, XfdfConstants.SQUIGGLY
, XfdfConstants.STAMP
, XfdfConstants.STRIKEOUT
, XfdfConstants.TEXT
, XfdfConstants.UNDERLINE
.
public List<AttributeObject> getAttributes()
public AttributeObject getAttribute(String name)
name
- The name of the attribute to look for.
AttributeObject
with the given name, or null, if no object with this name was found.
public String getAttributeValue(String name)
name
- The name of the attribute to look for.
AttributeObject
with the given name, or null, if no object with this name was found.
public AnnotObject getPopup()
public AnnotObject setPopup(AnnotObject popup)
public boolean isHasPopup()
public AnnotObject setHasPopup(boolean hasPopup)
public PdfString getContents()
public AnnotObject setContents(PdfString contents)
public PdfString getContentsRichText()
public AnnotObject setContentsRichText(PdfString contentsRichRext)
public ActionObject getAction()
public AnnotObject setAction(ActionObject action)
public void addAttribute(AttributeObject attr)
AttributeObject
to the list of annotation attributes.
attr
- attribute to be added.
public DestObject getDestination()
public AnnotObject setDestination(DestObject destination)
public String getAppearance()
public AnnotObject setAppearance(String appearance)
public String getDefaultAppearance()
public AnnotObject setDefaultAppearance(String defaultAppearance)
public String getDefaultStyle()
public AnnotObject setDefaultStyle(String defaultStyle)
public BorderStyleAltObject getBorderStyleAlt()
public AnnotObject setBorderStyleAlt(BorderStyleAltObject borderStyleAlt)
public String getVertices()
public AnnotObject setVertices(String vertices)
public PdfIndirectReference getRef()
PdfAnnotation
. Used for attaching popups in case of reading data from pdf file.
public AnnotObject setRef(PdfIndirectReference ref)
PdfAnnotation
. Used for attaching popups in case of reading data from pdf file.
Copyright © 1998–2020 iText Group NV. All rights reserved.