com.aspose.pdf.elements
Class Attachment

java.lang.Object
  extended by com.aspose.pdf.elements.PdfElementBase
      extended by com.aspose.pdf.elements.Paragraph
          extended by com.aspose.pdf.elements.Attachment
All Implemented Interfaces:
java.lang.Cloneable

public class Attachment
extends Paragraph

Represents an annotation Paragraph in a Pdf document.


Constructor Summary
Attachment(Section section)
          Initializes a new instance of the Attachment class.
Attachment(Section section, Rectangle rect)
          Initializes a new instance of the Attachment class.
 
Method Summary
 AnnotationIconType getAnnotationIconType()
          Gets the type of the annotation icon.
 java.lang.String getAttachedFileName()
          Gets a string that indicates the attach file name.
 byte[] getAttachedStream()
          Gets a stream attaches to the file.
 AttachmentType getAttachType()
          Gets AttachmentType that indicates the attachment type.
 java.lang.String getDescription()
          Gets a string that indicates the description of attached file.
 FileIconType getFileIconType()
          Gets a FileIconType that indicates the file attachment icon type.
 Color getIconColor()
          Represents a Color object that indicates the color of the icon.
 float getIconOpacity()
          Gets a float value between 0.0 and 1.0 that indicates the opacity of the image.
 java.lang.String getNoteContent()
          Gets a string that indicates the content of the attached note.
 java.lang.String getNoteHeading()
          Gets a string that indicates the heading (title) of the attached note.
 Rectangle getNoteWindowPosition()
          Gets a RectangleArea object that indicates the position of the note's popup window.
 boolean isNoteOpen()
          Gets a bool value that indicates whether the note is open or not when the Pdf document is opened.
 void setAnnotationIconType(AnnotationIconType annotationIconType)
          Sets the type of the annotation icon.
 void setAttachedFileName(java.lang.String attachedFileName)
          Sets a string that indicates the attach file name.
 void setAttachedStream(byte[] attachedStream)
          Sets a stream attaches to the file.
 void setAttachType(AttachmentType attachType)
          Sets AttachmentType that indicates the attachment type.
 void setDescription(java.lang.String discription)
          Sets a string that indicates the description of attached file.
 void setFileIconType(FileIconType iconType)
          Sets a FileIconType that indicates the file attachment icon type.
 void setIconColor(Color iconColor)
          Sets a Color object that indicates the color of the icon.
 void setIconOpacity(float iconOpacity)
          Sets a float value between 0.0 and 1.0 that indicates the opacity of the image.
 void setNoteContent(java.lang.String noteContent)
          Sets a string that indicates the content of the attached note.
 void setNoteHeading(java.lang.String noteHeading)
          Sets a string that indicates the heading (title) of the attached note.
 void setNoteOpen(boolean isNoteOpen)
          Sets a bool value that indicates whether the note is open or not when the Pdf document is opened.
 void setNoteWindowPosition(Rectangle noteWindowPosition)
          Sets a RectangleArea object that indicates the position of the note's popup window.
 
Methods inherited from class com.aspose.pdf.elements.Paragraph
clone, getDOMElement, getLeft, getMargin, getTop, isDisabled, isFirstParagraph, isKeptTogether, isOnOddPage, setDisabled, setFirstParagraph, setKeptTogether, setLeft, setMargin, setOnOddPage, setTop
 
Methods inherited from class com.aspose.pdf.elements.PdfElementBase
getElementFactory, getID, getNameIndex, setID
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Attachment

public Attachment(Section section)
Initializes a new instance of the Attachment class.

Parameters:
section - the Section this attachment in.

Attachment

public Attachment(Section section,
                  Rectangle rect)
Initializes a new instance of the Attachment class.

Parameters:
section - the Section this attachment in.
rect - the position the attachment in.
Method Detail

isNoteOpen

public boolean isNoteOpen()
Gets a bool value that indicates whether the note is open or not when the Pdf document is opened.


setNoteOpen

public void setNoteOpen(boolean isNoteOpen)
Sets a bool value that indicates whether the note is open or not when the Pdf document is opened.


getNoteContent

public java.lang.String getNoteContent()
Gets a string that indicates the content of the attached note.


setNoteContent

public void setNoteContent(java.lang.String noteContent)
Sets a string that indicates the content of the attached note.


getNoteHeading

public java.lang.String getNoteHeading()
Gets a string that indicates the heading (title) of the attached note.


setNoteHeading

public void setNoteHeading(java.lang.String noteHeading)
Sets a string that indicates the heading (title) of the attached note.


getNoteWindowPosition

public Rectangle getNoteWindowPosition()
Gets a RectangleArea object that indicates the position of the note's popup window.


setNoteWindowPosition

public void setNoteWindowPosition(Rectangle noteWindowPosition)
Sets a RectangleArea object that indicates the position of the note's popup window.


getAnnotationIconType

public AnnotationIconType getAnnotationIconType()
Gets the type of the annotation icon.


setAnnotationIconType

public void setAnnotationIconType(AnnotationIconType annotationIconType)
Sets the type of the annotation icon.


getAttachType

public AttachmentType getAttachType()
Gets AttachmentType that indicates the attachment type.


setAttachType

public void setAttachType(AttachmentType attachType)
Sets AttachmentType that indicates the attachment type.

Parameters:
attachType - AttachmentType you want to set.

getAttachedFileName

public java.lang.String getAttachedFileName()
Gets a string that indicates the attach file name.


setAttachedFileName

public void setAttachedFileName(java.lang.String attachedFileName)
Sets a string that indicates the attach file name.


getAttachedStream

public byte[] getAttachedStream()
Gets a stream attaches to the file.


setAttachedStream

public void setAttachedStream(byte[] attachedStream)
Sets a stream attaches to the file.


getDescription

public java.lang.String getDescription()
Gets a string that indicates the description of attached file.


setDescription

public void setDescription(java.lang.String discription)
Sets a string that indicates the description of attached file.


getFileIconType

public FileIconType getFileIconType()
Gets a FileIconType that indicates the file attachment icon type.


setFileIconType

public void setFileIconType(FileIconType iconType)
Sets a FileIconType that indicates the file attachment icon type.


getIconColor

public Color getIconColor()
Represents a Color object that indicates the color of the icon.


setIconColor

public void setIconColor(Color iconColor)
Sets a Color object that indicates the color of the icon.


getIconOpacity

public float getIconOpacity()
Gets a float value between 0.0 and 1.0 that indicates the opacity of the image. The default value is 1.0.


setIconOpacity

public void setIconOpacity(float iconOpacity)
Sets a float value between 0.0 and 1.0 that indicates the opacity of the image. The default value is 1.0.

Parameters:
iconOpacity - the Opacity value you want to set