Image
Inheritance: java.lang.Object, com.aspose.note.Node
All Implemented Interfaces: com.aspose.note.IPageChildNode, com.aspose.note.IOutlineElementChildNode, com.aspose.note.ITaggable
public final class Image extends Node implements IPageChildNode, IOutlineElementChildNode, ITaggable
Represents an Image.
Constructors
Constructor | Description |
---|---|
Image(String path) | Initializes a new instance of the Image class. |
Image(String fileName, InputStream imageStream) | Initializes a new instance of the Image class. |
Image() | Initializes a new instance of the Image class. |
Methods
Method | Description |
---|---|
getLastModifiedTime() | Gets last modified time. |
setLastModifiedTime(Date value) | Sets last modified time. |
getWidth() | Gets the width. |
setWidth(float value) | Sets the width. |
getHeight() | Gets the height. |
setHeight(float value) | Sets the height. |
isBackground() | Gets whether the image is a background image. |
setBackground(boolean value) | Gets whether the image is a background image. |
getOriginalWidth() | Gets the original width. |
getOriginalHeight() | Gets the original height. |
getHorizontalOffset() | Gets the horizontal offset. |
setHorizontalOffset(float value) | Sets the horizontal offset. |
getVerticalOffset() | Gets the vertical offset. |
setVerticalOffset(float value) | Sets the vertical offset. |
getFilePath() | Gets the path to the image file. |
getFileName() | Gets the file name. |
getFormat() | Gets the image’s format. |
getBytes() | Gets the image data store. |
getTags() | Gets the list of all tags of an image. |
getAlignment() | Gets the alignment. |
setAlignment(int value) | Sets the alignment. |
getAlternativeTextTitle() | Gets a title of alternative text for the image. |
setAlternativeTextTitle(String value) | Sets a title of alternative text for the image. |
getAlternativeTextDescription() | Gets a body an alternative text for the image. |
setAlternativeTextDescription(String value) | Sets a body an alternative text for the image. |
getHyperlinkUrl() | Gets the hyperlink associated with the image. |
setHyperlinkUrl(String value) | Sets the hyperlink associated with the image. |
accept(DocumentVisitor visitor) | Accepts the visitor of the node. |
Image(String path)
public Image(String path)
Initializes a new instance of the Image class.
Parameters:
Parameter | Type | Description |
---|---|---|
path | java.lang.String | A string that contains the path to the file from which to create the Image . |
Image(String fileName, InputStream imageStream)
public Image(String fileName, InputStream imageStream)
Initializes a new instance of the Image class.
Parameters:
Parameter | Type | Description |
---|---|---|
fileName | java.lang.String | A name of the image. |
imageStream | java.io.InputStream | A stream which contains the image. |
Image()
public Image()
Initializes a new instance of the Image class.
getLastModifiedTime()
public Date getLastModifiedTime()
Gets last modified time.
Returns: java.util.Date
setLastModifiedTime(Date value)
public void setLastModifiedTime(Date value)
Sets last modified time.
Parameters:
Parameter | Type | Description |
---|---|---|
value | java.util.Date |
getWidth()
public float getWidth()
Gets the width. This is the real width of the image in the MS OneNote document.
Returns: float
setWidth(float value)
public void setWidth(float value)
Sets the width. This is the real width of the image in the MS OneNote document.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getHeight()
public float getHeight()
Gets the height. This is the real height of the image in the MS OneNote document.
Returns: float
setHeight(float value)
public void setHeight(float value)
Sets the height. This is the real height of the image in the MS OneNote document.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
isBackground()
public final boolean isBackground()
Gets whether the image is a background image.
Returns: boolean
setBackground(boolean value)
public final void setBackground(boolean value)
Gets whether the image is a background image.
Parameters:
Parameter | Type | Description |
---|---|---|
value | boolean |
getOriginalWidth()
public float getOriginalWidth()
Gets the original width. This is the original width of the image, before resizing.
Returns: float
getOriginalHeight()
public float getOriginalHeight()
Gets the original height. This is the original width of the image, before resizing.
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:
Parameter | Type | Description |
---|---|---|
value | float |
getVerticalOffset()
public float getVerticalOffset()
Gets the vertical offset.
Returns: float
setVerticalOffset(float value)
public void setVerticalOffset(float value)
Sets the vertical offset.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getFilePath()
public String getFilePath()
Gets the path to the image file.
Returns: java.lang.String
getFileName()
public String getFileName()
Gets the file name.
Returns: java.lang.String
getFormat()
public final System.Drawing.Imaging.ImageFormat getFormat()
Gets the image’s format.
Returns: com.aspose.ms.System.Drawing.Imaging.ImageFormat
getBytes()
public byte[] getBytes()
Gets the image data store.
Returns: byte[]
getTags()
public final System.Collections.Generic.List<ITag> getTags()
Gets the list of all tags of an image.
Returns: com.aspose.ms.System.Collections.Generic.List<com.aspose.note.ITag>
getAlignment()
public int getAlignment()
Gets the alignment.
Returns: int
setAlignment(int value)
public void setAlignment(int value)
Sets the alignment.
Parameters:
Parameter | Type | Description |
---|---|---|
value | int |
getAlternativeTextTitle()
public final String getAlternativeTextTitle()
Gets a title of alternative text for the image.
Returns: java.lang.String
setAlternativeTextTitle(String value)
public final void setAlternativeTextTitle(String value)
Sets a title of alternative text for the image.
Parameters:
Parameter | Type | Description |
---|---|---|
value | java.lang.String |
getAlternativeTextDescription()
public final String getAlternativeTextDescription()
Gets a body an alternative text for the image.
Returns: java.lang.String
setAlternativeTextDescription(String value)
public final void setAlternativeTextDescription(String value)
Sets a body an alternative text for the image.
Parameters:
Parameter | Type | Description |
---|---|---|
value | java.lang.String |
getHyperlinkUrl()
public String getHyperlinkUrl()
Gets the hyperlink associated with the image.
Returns: java.lang.String
setHyperlinkUrl(String value)
public void setHyperlinkUrl(String value)
Sets the hyperlink associated with the image.
Parameters:
Parameter | Type | Description |
---|---|---|
value | java.lang.String |
accept(DocumentVisitor visitor)
public void accept(DocumentVisitor visitor)
Accepts the visitor of the node.
Parameters:
Parameter | Type | Description |
---|---|---|
visitor | DocumentVisitor | The object of a class derived from the DocumentVisitor . |