com.aspose.note

Class AttachedFile

    • Constructor Detail

      • AttachedFile

        public AttachedFile(Document document,
                            String path)

        Initializes a new instance of the AttachedFile class.

        Parameters:
        document - A parent document of the attached file.
        path - A string that contains the path to the file from which to create the AttachedFile.
      • AttachedFile

        public AttachedFile(Document document,
                            String path,
                            InputStream icon,
                            com.aspose.ms.System.Drawing.Imaging.ImageFormat iconFormat)

        Initializes a new instance of the AttachedFile class.

        Parameters:
        document - A parent document of the attached file.
        path - A string that contains the path to the file from which to create the AttachedFile.
        icon - An icon for the attached file.
        iconFormat - A format of the attached file icon.
      • AttachedFile

        public AttachedFile(Document document,
                            String fileName,
                            InputStream attachedFileStream)

        Initializes a new instance of the AttachedFile class.

        Parameters:
        document - A parent document of the attached file.
        fileName - A name of the attached file.
        attachedFileStream - A stream which contains the attached file bytes.
      • AttachedFile

        public AttachedFile(Document document,
                            String fileName,
                            InputStream attachedFileStream,
                            InputStream icon,
                            com.aspose.ms.System.Drawing.Imaging.ImageFormat iconFormat)

        Initializes a new instance of the AttachedFile class.

        Parameters:
        document - A parent document of the attached file.
        fileName - A name of the attached file.
        attachedFileStream - A stream which contains the attached file bytes.
        icon - An icon for the attached file.
        iconFormat - A format of the attached file icon.
    • Method Detail

      • getLastModifiedTime

        public Date getLastModifiedTime()

        Gets or sets the last modified time.

      • setLastModifiedTime

        public void setLastModifiedTime(Date value)

        Gets or sets the last modified time.

      • getMaxWidth

        public float getMaxWidth()

        Gets or sets the maximum width to display the embedded file icon.

      • setMaxWidth

        public void setMaxWidth(float value)

        Gets or sets the maximum width to display the embedded file icon.

      • getMaxHeight

        public float getMaxHeight()

        Gets or sets the maximum height to display the embedded file icon.

      • setMaxHeight

        public void setMaxHeight(float value)

        Gets or sets the maximum height to display the embedded file icon.

      • isSizeSetByUser

        public boolean isSizeSetByUser()

        Gets or sets a value indicating whether the value of the size of the icon was explicitly updated by the user.

      • setSizeSetByUser

        public void setSizeSetByUser(boolean value)

        Gets or sets a value indicating whether the value of the size of the icon was explicitly updated by the user.

      • getText

        public String getText()

        Gets or sets the text representation of the embedded file. The string MUST NOT contain any characters of the value 10 (line feed) or 13 (carriage return).

      • setText

        public void setText(String value)

        Gets or sets the text representation of the embedded file. The string MUST NOT contain any characters of the value 10 (line feed) or 13 (carriage return).

      • getAlignment

        public int getAlignment()

        Gets or sets the alignment.

      • setAlignment

        public void setAlignment(int value)

        Gets or sets the alignment.

      • getFileName

        public String getFileName()

        Gets the name of the embedded file.

      • getFilePath

        public String getFilePath()

        Gets the path to the original file.

      • getWidth

        public float getWidth()

        Gets the original width of the embedded file icon.

      • getHeight

        public float getHeight()

        Gets the original height of the embedded file icon.

      • getHorizontalOffset

        public float getHorizontalOffset()

        Gets or sets the horizontal offset.

      • setHorizontalOffset

        public void setHorizontalOffset(float value)

        Gets or sets the horizontal offset.

      • getVerticalOffset

        public float getVerticalOffset()

        Gets or sets the vertical offset.

      • setVerticalOffset

        public void setVerticalOffset(float value)

        Gets or sets the vertical offset.

      • getIcon

        public byte[] getIcon()

        Gets the binary data for the icon that is associated with the embedded file.

      • getIconExtension

        public String getIconExtension()

        Gets the extension of the icon.

      • getBytes

        public byte[] getBytes()

        Gets the binary data for an embedded file.

      • getExtension

        public String getExtension()

        Gets the extension of an embedded file.

      • isPrintout

        public boolean isPrintout()

        Gets or sets a value indicating whether the view of the file is printout.

      • setPrintout

        public void setPrintout(boolean value)

        Gets or sets a value indicating whether the view of the file is printout.

      • getTags

        public List<NoteTagCore> getTags()

        Gets the list of tags of an attached file.

      • accept

        public void accept(DocumentVisitor visitor)

        Accepts the visitor of the node.

        Specified by:
        accept in interface INode
        Specified by:
        accept in class Node
        Parameters:
        visitor - The object of a class derived from the DocumentVisitor.