AttachedFile

Inheritance: java.lang.Object, com.aspose.note.Node

All Implemented Interfaces: com.aspose.note.IPageChildNode, com.aspose.note.IOutlineElementChildNode, com.aspose.note.ITaggable

public class AttachedFile extends Node implements IPageChildNode, IOutlineElementChildNode, ITaggable

Represents an attached file.

Constructors

ConstructorDescription
AttachedFile(String path)Initializes a new instance of the AttachedFile class.
AttachedFile(String path, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)Initializes a new instance of the AttachedFile class.
AttachedFile(String fileName, InputStream attachedFileStream)Initializes a new instance of the AttachedFile class.
AttachedFile(String fileName, InputStream attachedFileStream, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)Initializes a new instance of the AttachedFile class.
AttachedFile()Initializes a new instance of the AttachedFile class.

Methods

MethodDescription
getLastModifiedTime()Gets the last modified time.
setLastModifiedTime(Date value)Sets the last modified time.
getMaxWidth()Gets the maximum width to display the embedded file icon.
setMaxWidth(float value)Sets the maximum width to display the embedded file icon.
getMaxHeight()Gets the maximum height to display the embedded file icon.
setMaxHeight(float value)Sets the maximum height to display the embedded file icon.
isSizeSetByUser()Gets a value indicating whether the value of the size of the icon was explicitly updated by the user.
setSizeSetByUser(boolean value)Sets a value indicating whether the value of the size of the icon was explicitly updated by the user.
getText()Gets the text representation of the embedded file.
setText(String value)Sets the text representation of the embedded file.
getAlternativeTextTitle()Gets or sets a title of alternative text for the icon of the attached file.
setAlternativeTextTitle(String value)Gets or sets a title of alternative text for the icon of the attached file.
getAlternativeTextDescription()Gets or sets a body an alternative text for the icon of the attached file.
setAlternativeTextDescription(String value)Gets or sets a body an alternative text for the icon of the attached file.
getAlignment()Gets the alignment.
setAlignment(int value)Sets the alignment.
getFileName()Gets the name of the embedded file.
getFilePath()Gets the path to the original file.
getWidth()Gets the original width of the embedded file icon.
getHeight()Gets the original height of the embedded file icon.
getHorizontalOffset()Gets the horizontal offset.
setHorizontalOffset(float value)Sets the horizontal offset.
getVerticalOffset()Gets the vertical offset.
setVerticalOffset(float value)Sets the vertical offset.
getIcon()Gets the binary data for the icon that is associated with the embedded file.
getIconExtension()Gets the extension of the icon.
getBytes()Gets the binary data for an embedded file.
getExtension()Gets the extension of an embedded file.
isPrintout()Gets a value indicating whether the view of the file is printout.
setPrintout(boolean value)Sets a value indicating whether the view of the file is printout.
getTags()Gets the list of tags of an attached file.
accept(DocumentVisitor visitor)Accepts the visitor of the node.

AttachedFile(String path)

public AttachedFile(String path)

Initializes a new instance of the AttachedFile class.

Parameters:

ParameterTypeDescription
pathjava.lang.StringA string that contains the path to the file from which to create the AttachedFile .

AttachedFile(String path, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)

public AttachedFile(String path, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)

Initializes a new instance of the AttachedFile class.

Parameters:

ParameterTypeDescription
pathjava.lang.StringA string that contains the path to the file from which to create the AttachedFile .
iconjava.io.InputStreamAn icon for the attached file.
iconFormatcom.aspose.ms.System.Drawing.Imaging.ImageFormat

AttachedFile(String fileName, InputStream attachedFileStream)

public AttachedFile(String fileName, InputStream attachedFileStream)

Initializes a new instance of the AttachedFile class.

Parameters:

ParameterTypeDescription
fileNamejava.lang.StringA name of the attached file.
attachedFileStreamjava.io.InputStreamA stream which contains the attached file bytes.

AttachedFile(String fileName, InputStream attachedFileStream, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)

public AttachedFile(String fileName, InputStream attachedFileStream, InputStream icon, System.Drawing.Imaging.ImageFormat iconFormat)

Initializes a new instance of the AttachedFile class.

Parameters:

ParameterTypeDescription
fileNamejava.lang.StringA name of the attached file.
attachedFileStreamjava.io.InputStreamA stream which contains the attached file bytes.
iconjava.io.InputStreamAn icon for the attached file.
iconFormatcom.aspose.ms.System.Drawing.Imaging.ImageFormatA format of the attached file icon.

AttachedFile()

public AttachedFile()

Initializes a new instance of the AttachedFile class.

getLastModifiedTime()

public Date getLastModifiedTime()

Gets the last modified time.

Returns: java.util.Date

setLastModifiedTime(Date value)

public void setLastModifiedTime(Date value)

Sets the last modified time.

Parameters:

ParameterTypeDescription
valuejava.util.DateDate’s value.

getMaxWidth()

public float getMaxWidth()

Gets the maximum width to display the embedded file icon.

Returns: float

setMaxWidth(float value)

public void setMaxWidth(float value)

Sets the maximum width to display the embedded file icon.

Parameters:

ParameterTypeDescription
valuefloatMaximum width’s value.

getMaxHeight()

public float getMaxHeight()

Gets the maximum height to display the embedded file icon.

Returns: float

setMaxHeight(float value)

public void setMaxHeight(float value)

Sets the maximum height to display the embedded file icon.

Parameters:

ParameterTypeDescription
valuefloatMaximum height’s value.

isSizeSetByUser()

public boolean isSizeSetByUser()

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

Returns: boolean

setSizeSetByUser(boolean value)

public void setSizeSetByUser(boolean value)

Sets a value indicating whether the value of the size of the icon was explicitly updated by the user.

Parameters:

ParameterTypeDescription
valuebooleanNew value.

getText()

public String getText()

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

Returns: java.lang.String

setText(String value)

public void setText(String value)

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).

Parameters:

ParameterTypeDescription
valuejava.lang.StringText’s value.

getAlternativeTextTitle()

public final String getAlternativeTextTitle()

Gets or sets a title of alternative text for the icon of the attached file.

Returns: java.lang.String

setAlternativeTextTitle(String value)

public final void setAlternativeTextTitle(String value)

Gets or sets a title of alternative text for the icon of the attached file.

Parameters:

ParameterTypeDescription
valuejava.lang.String

getAlternativeTextDescription()

public final String getAlternativeTextDescription()

Gets or sets a body an alternative text for the icon of the attached file.

Returns: java.lang.String

setAlternativeTextDescription(String value)

public final void setAlternativeTextDescription(String value)

Gets or sets a body an alternative text for the icon of the attached file.

Parameters:

ParameterTypeDescription
valuejava.lang.String

getAlignment()

public int getAlignment()

Gets the alignment.

Returns: int

setAlignment(int value)

public void setAlignment(int value)

Sets the alignment.

Parameters:

ParameterTypeDescription
valueintAlignment’s value.

getFileName()

public String getFileName()

Gets the name of the embedded file.

Returns: java.lang.String

getFilePath()

public String getFilePath()

Gets the path to the original file.

Returns: java.lang.String

getWidth()

public float getWidth()

Gets the original width of the embedded file icon.

Returns: float

getHeight()

public float getHeight()

Gets the original height of the embedded file icon.

Returns: float

getHorizontalOffset()

public float getHorizontalOffset()

Gets the horizontal offset.

Returns: float

setHorizontalOffset(float value)

public void setHorizontalOffset(float value)

Sets the horizontal offset.

Parameters:

ParameterTypeDescription
valuefloatOffsets’s value.

getVerticalOffset()

public float getVerticalOffset()

Gets the vertical offset.

Returns: float

setVerticalOffset(float value)

public void setVerticalOffset(float value)

Sets the vertical offset.

Parameters:

ParameterTypeDescription
valuefloatOffset’s value.

getIcon()

public byte[] getIcon()

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

Returns: byte[]

getIconExtension()

public String getIconExtension()

Gets the extension of the icon.

Returns: java.lang.String

getBytes()

public byte[] getBytes()

Gets the binary data for an embedded file.

Returns: byte[]

getExtension()

public String getExtension()

Gets the extension of an embedded file.

Returns: java.lang.String

isPrintout()

public boolean isPrintout()

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

Returns: boolean

setPrintout(boolean value)

public void setPrintout(boolean value)

Sets a value indicating whether the view of the file is printout.

Parameters:

ParameterTypeDescription
valuebooleanNew value.

getTags()

public final System.Collections.Generic.List<ITag> getTags()

Gets the list of tags of an attached file.

Returns: com.aspose.ms.System.Collections.Generic.List<com.aspose.note.ITag>

accept(DocumentVisitor visitor)

public void accept(DocumentVisitor visitor)

Accepts the visitor of the node.

Parameters:

ParameterTypeDescription
visitorDocumentVisitorThe object of a class derived from the DocumentVisitor .