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

## org.pdfbox.pdmodel.interactive.annotation
Class PDAnnotationText

    java.lang.Object
      org.pdfbox.pdmodel.interactive.annotation.PDAnnotation
          org.pdfbox.pdmodel.interactive.annotation.PDAnnotationMarkup
              org.pdfbox.pdmodel.interactive.annotation.PDAnnotationText

All Implemented Interfaces:
  COSObjectable

public class PDAnnotationText
extends PDAnnotationMarkup

This is the class that represents a text annotation.

Version:
  $Revision: 1.1 $
Author:
  Paul King

Field Summary
`static String` | `NAME_COMMENT` Constant for the name of a text annotation.
`static String` | `NAME_HELP` Constant for the name of a text annotation.
`static String` | `NAME_INSERT` Constant for the name of a text annotation.
`static String` | `NAME_KEY` Constant for the name of a text annotation.
`static String` | `NAME_NEW_PARAGRAPH` Constant for the name of a text annotation.
`static String` | `NAME_NOTE` Constant for the name of a text annotation.
`static String` | `NAME_PARAGRAPH` Constant for the name of a text annotation.
`static String` | `SUB_TYPE` The type of annotation.

Fields inherited from class org.pdfbox.pdmodel.interactive.annotation.PDAnnotationMarkup
`RT_GROUP, RT_REPLY`

Fields inherited from class org.pdfbox.pdmodel.interactive.annotation.PDAnnotation
`FLAG_HIDDEN, FLAG_INVISIBLE, FLAG_LOCKED, FLAG_NO_ROTATE, FLAG_NO_VIEW, FLAG_NO_ZOOM, FLAG_PRINTED, FLAG_READ_ONLY, FLAG_TOGGLE_NO_VIEW`

Constructor Summary
`PDAnnotationText()` Constructor.
`PDAnnotationText(COSDictionary field)` Creates a Text annotation from a COSDictionary, expected to be a correct object definition.

Method Summary
`String` | `getName()` This will retrieve the name (and hence appearance, AP taking precedence) For this annotation.
`boolean` | `getOpen()` This will retrieve the initial state of the annotation, open Or closed (default closed).
`void` | `setName(String name)` This will set the name (and hence appearance, AP taking precedence) For this annotation.
`void` | `setOpen(boolean open)` This will set inital state of the annotation, open or closed.

Methods inherited from class org.pdfbox.pdmodel.interactive.annotation.PDAnnotationMarkup
`getConstantOpacity, getCreationDate, getInReplyTo, getIntent, getPopup, getReplyType, getRichContents, getSubject, getTitlePopup, setConstantOpacity, setCreationDate, setInReplyTo, setIntent, setPopup, setReplyType, setRichContents, setSubject, setTitlePopup`

Methods inherited from class org.pdfbox.pdmodel.interactive.annotation.PDAnnotation
`createAnnotation, getAction, getActions, getAnnotationFlags, getAnnotationName, getAppearance, getAppearanceStream, getBoderStyle, getColour, getContents, getCOSObject, getDictionary, getModifiedDate, getRectangle, isHidden, isInvisible, isLocked, isNoRotate, isNoView, isNoZoom, isPrinted, isReadOnly, isToggleNoView, setAction, setActions, setAnnotationFlags, setAnnotationName, setAppearance, setAppearanceStream, setBorderStyle, setColour, setContents, setHidden, setInvisible, setLocked, setModifiedDate, setNoRotate, setNoView, setNoZoom, setPrinted, setReadOnly, setRectangle, setToggleNoView`

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

Field Detail

### NAME_COMMENT

    public static final String NAME_COMMENT

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_KEY

    public static final String NAME_KEY

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_NOTE

    public static final String NAME_NOTE

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_HELP

    public static final String NAME_HELP

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_NEW_PARAGRAPH

    public static final String NAME_NEW_PARAGRAPH

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_PARAGRAPH

    public static final String NAME_PARAGRAPH

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### NAME_INSERT

    public static final String NAME_INSERT

  Constant for the name of a text annotation.

  See Also:
    Constant Field Values

### SUB_TYPE

    public static final String SUB_TYPE

  The type of annotation.

  See Also:
    Constant Field Values

Constructor Detail

### PDAnnotationText

    public PDAnnotationText()

  Constructor.

### PDAnnotationText

    public PDAnnotationText(COSDictionary field)

  Creates a Text annotation from a COSDictionary, expected to be a correct object definition.

Parameters:
  `field` - the PDF objet to represent as a field.

Method Detail

### setOpen

    public void setOpen(boolean open)

  This will set inital state of the annotation, open or closed.

  Parameters:
    `open` - Boolean value, true = open false = closed

### getOpen

    public boolean getOpen()

  This will retrieve the initial state of the annotation, open Or closed (default closed).

  Returns:
    The initial state, true = open false = closed

### setName

    public void setName(String name)

  This will set the name (and hence appearance, AP taking precedence) For this annotation. See the NAME_XXX constants for valid values.

  Parameters:
    `name` - The name of the annotation

### getName

    public String getName()

  This will retrieve the name (and hence appearance, AP taking precedence) For this annotation. The default is NOTE.

  Returns:
    The name of this annotation, see the NAME_XXX constants.

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