HtmlSaveOptions

Inheritance: java.lang.Object, com.aspose.email.SaveOptions, com.aspose.email.HeadersFormattingOptions

public class HtmlSaveOptions extends HeadersFormattingOptions

Allows to specify additional options when saving MailMessage to Html format.

Constructors

ConstructorDescription
HtmlSaveOptions()Initializes a new instance of this class that can be used to save a MailMessage in the Html format.

Methods

MethodDescription
createSaveOptions(MailMessageSaveType saveType)Creates a save options object of a class suitable for the specified save type.
equals(Object arg0)
getAfterHeadersFormat()After headers format.
getBeforeHeadersFormat()Before headers format.
getCheckBodyContentEncoding()Defines whether need check message body content encoding when saving.
getClass()
getCssStyles()Gets or sets the additional css styles for the formatter.
getCustomProgressHandler()Represents method that usually supplied by calling side and handles progress events.
getDefaultEml()Gets options with default values for saving message to Eml format.
getDefaultEmlx()Gets options with default values for saving message to Emlx format.
getDefaultHeaderFormat()Default header line format.
getDefaultHtml()Gets options with default values for saving message to Html format.
getDefaultMhtml()Gets options with default values for saving message to Mhtml format.
getDefaultMsg()Gets options with default values for saving message to Msg(ASCII) format.
getDefaultMsgUnicode()Gets options with default values for saving message to Msg(Unicode) format.
getDefaultOft()Gets options with default values for saving message to Outlook template (Oft) format.
getDefaultPageHeaderFormat()Default page header format.
getFormatTemplates()Gets the format templates.
getHtmlFormatOptions()Gets or sets additional options when saving in HTML format.
getMailMessageSaveType()Represents the mail message save type.It can be in eml,msg(ASCII or Unicode),mhtml or html format.
getRenderedContactFields()Defines groups of Contact fields which will be included in output mhtml.
getRenderingHeaders()Gets list of headers for rendering.
getResourceHtmlRenderingHandler()Provides customization of rendering resources in html.
getResourceRenderingMode()Provides set various modes of rendering resources in html.
getUseRelativePathToResources()If true then resources will be saved in folder htmlFileName.files in the same folder that html file and the relative path to resources will be added in html content , otherwise absolute path from ResourceHtmlRenderingEventArgs.PathToResourceFile property will be used for saving resources and adding to html.
hashCode()
notify()
notifyAll()
setAfterHeadersFormat(String value)After headers format.
setBeforeHeadersFormat(String value)Before headers format.
setCheckBodyContentEncoding(boolean value)Defines whether need check message body content encoding when saving.
setCssStyles(String value)Gets or sets the additional css styles for the formatter.
setCustomProgressHandler(ConversionProgressEventHandler value)Represents method that usually supplied by calling side and handles progress events.
setDefaultHeaderFormat(String value)Default header line format.
setDefaultPageHeaderFormat(String value)Default page header format.
setHtmlFormatOptions(int value)Gets or sets additional options when saving in HTML format.
setMailMessageSaveType(MailMessageSaveType value)Represents the mail message save type.It can be in eml,msg(ASCII or Unicode),mhtml or html format.
setRenderedContactFields(int value)Defines groups of Contact fields which will be included in output mhtml.
setResourceHtmlRenderingHandler(ResourceHtmlRenderingHandler value)Provides customization of rendering resources in html.
setResourceRenderingMode(int value)Provides set various modes of rendering resources in html.
setUseRelativePathToResources(boolean value)If true then resources will be saved in folder htmlFileName.files in the same folder that html file and the relative path to resources will be added in html content , otherwise absolute path from ResourceHtmlRenderingEventArgs.PathToResourceFile property will be used for saving resources and adding to html.
toString()
wait()
wait(long arg0)
wait(long arg0, int arg1)

HtmlSaveOptions()

public HtmlSaveOptions()

Initializes a new instance of this class that can be used to save a MailMessage in the Html format.

createSaveOptions(MailMessageSaveType saveType)

public static SaveOptions createSaveOptions(MailMessageSaveType saveType)

Creates a save options object of a class suitable for the specified save type.

Parameters:

ParameterTypeDescription
saveTypeMailMessageSaveTypeThe MailMessageSaveTypesave type (#getMailMessageSaveType.getMailMessageSaveType/#setMailMessageSaveType(MailMessageSaveType).setMailMessageSaveType(MailMessageSaveType)) for which to create a save options object.

Returns: SaveOptions - An object of a class that derives from SaveOptions.

equals(Object arg0)

public boolean equals(Object arg0)

Parameters:

ParameterTypeDescription
arg0java.lang.Object

Returns: boolean

getAfterHeadersFormat()

public final String getAfterHeadersFormat()

After headers format.

Value: The styles to be injected into resulting html body.

Returns: java.lang.String

getBeforeHeadersFormat()

public final String getBeforeHeadersFormat()

Before headers format.

Value: The styles to be injected into resulting html body.

Returns: java.lang.String

getCheckBodyContentEncoding()

public final boolean getCheckBodyContentEncoding()

Defines whether need check message body content encoding when saving. By default the value is false.


If true, it will be check whether the MailMessage.HtmlBody (MailMessage.getHtmlBody/MailMessage.setHtmlBody(String)) content encoding matches to the encoding specified by the MailMessage.BodyEncoding (MailMessage.getBodyEncoding/MailMessage.setBodyEncoding(Encoding)) property. If the HtmlBody content encoding doesn’t match BodyEncoding property, the MailMessage.BodyEncoding (MailMessage.getBodyEncoding/MailMessage.setBodyEncoding(Encoding)) and MailMessage.PreferredTextEncoding (MailMessage.getPreferredTextEncoding/MailMessage.setPreferredTextEncoding(Encoding)) properties will be changed to default System.Text.Encoding.UTF8 (java.nio.charset.Charset#getUTF8.getUTF8).

Returns: boolean

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

getCssStyles()

public final String getCssStyles()

Gets or sets the additional css styles for the formatter.

Value: The styles to be injected into resulting html body.

Returns: java.lang.String

getCustomProgressHandler()

public final ConversionProgressEventHandler getCustomProgressHandler()

Represents method that usually supplied by calling side and handles progress events.

Returns: ConversionProgressEventHandler

getDefaultEml()

public static EmlSaveOptions getDefaultEml()

Gets options with default values for saving message to Eml format.

Returns: EmlSaveOptions

getDefaultEmlx()

public static EmlSaveOptions getDefaultEmlx()

Gets options with default values for saving message to Emlx format.

Returns: EmlSaveOptions

getDefaultHeaderFormat()

public final String getDefaultHeaderFormat()

Default header line format.

Value: The styles to be injected into resulting html body.

Returns: java.lang.String

getDefaultHtml()

public static HtmlSaveOptions getDefaultHtml()

Gets options with default values for saving message to Html format.

Returns: HtmlSaveOptions

getDefaultMhtml()

public static MhtSaveOptions getDefaultMhtml()

Gets options with default values for saving message to Mhtml format.

Returns: MhtSaveOptions

getDefaultMsg()

public static MsgSaveOptions getDefaultMsg()

Gets options with default values for saving message to Msg(ASCII) format.

Returns: MsgSaveOptions

getDefaultMsgUnicode()

public static MsgSaveOptions getDefaultMsgUnicode()

Gets options with default values for saving message to Msg(Unicode) format.

Returns: MsgSaveOptions

getDefaultOft()

public static MsgSaveOptions getDefaultOft()

Gets options with default values for saving message to Outlook template (Oft) format.

Returns: MsgSaveOptions

getDefaultPageHeaderFormat()

public final String getDefaultPageHeaderFormat()

Default page header format.

Value: The styles to be injected into resulting html body.

Returns: java.lang.String

getFormatTemplates()

public final System.Collections.Specialized.StringDictionary getFormatTemplates()

Gets the format templates.

Value: The format templates.

Returns: com.aspose.ms.System.Collections.Specialized.StringDictionary

getHtmlFormatOptions()

public final int getHtmlFormatOptions()

Gets or sets additional options when saving in HTML format. Default value is HtmlFormatOptions.None.

Returns: int

getMailMessageSaveType()

public final MailMessageSaveType getMailMessageSaveType()

Represents the mail message save type.It can be in eml,msg(ASCII or Unicode),mhtml or html format. The default value is Eml.

Returns: MailMessageSaveType

getRenderedContactFields()

public final int getRenderedContactFields()

Defines groups of Contact fields which will be included in output mhtml. Default value is ContactFieldsSet.AllExisting.

Returns: int

getRenderingHeaders()

public final List<String> getRenderingHeaders()

Gets list of headers for rendering.

Returns: java.util.List<java.lang.String>

getResourceHtmlRenderingHandler()

public final ResourceHtmlRenderingHandler getResourceHtmlRenderingHandler()

Provides customization of rendering resources in html.

Returns: ResourceHtmlRenderingHandler

getResourceRenderingMode()

public final int getResourceRenderingMode()

Provides set various modes of rendering resources in html. Default value EmbedIntoHtml.

Returns: int

getUseRelativePathToResources()

public final boolean getUseRelativePathToResources()

If true then resources will be saved in folder htmlFileName.files in the same folder that html file and the relative path to resources will be added in html content , otherwise absolute path from ResourceHtmlRenderingEventArgs.PathToResourceFile property will be used for saving resources and adding to html. It make sense if ResourceRenderingMode is ResourceRenderingMode.SaveToFile. Default value is false.

Returns: boolean

hashCode()

public native int hashCode()

Returns: int

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

setAfterHeadersFormat(String value)

public final void setAfterHeadersFormat(String value)

After headers format.

Value: The styles to be injected into resulting html body.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setBeforeHeadersFormat(String value)

public final void setBeforeHeadersFormat(String value)

Before headers format.

Value: The styles to be injected into resulting html body.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setCheckBodyContentEncoding(boolean value)

public final void setCheckBodyContentEncoding(boolean value)

Defines whether need check message body content encoding when saving. By default the value is false.


If true, it will be check whether the MailMessage.HtmlBody (MailMessage.getHtmlBody/MailMessage.setHtmlBody(String)) content encoding matches to the encoding specified by the MailMessage.BodyEncoding (MailMessage.getBodyEncoding/MailMessage.setBodyEncoding(Encoding)) property. If the HtmlBody content encoding doesn’t match BodyEncoding property, the MailMessage.BodyEncoding (MailMessage.getBodyEncoding/MailMessage.setBodyEncoding(Encoding)) and MailMessage.PreferredTextEncoding (MailMessage.getPreferredTextEncoding/MailMessage.setPreferredTextEncoding(Encoding)) properties will be changed to default System.Text.Encoding.UTF8 (java.nio.charset.Charset#getUTF8.getUTF8).

Parameters:

ParameterTypeDescription
valueboolean

setCssStyles(String value)

public final void setCssStyles(String value)

Gets or sets the additional css styles for the formatter.

Value: The styles to be injected into resulting html body.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setCustomProgressHandler(ConversionProgressEventHandler value)

public final void setCustomProgressHandler(ConversionProgressEventHandler value)

Represents method that usually supplied by calling side and handles progress events.

Parameters:

ParameterTypeDescription
valueConversionProgressEventHandler

setDefaultHeaderFormat(String value)

public final void setDefaultHeaderFormat(String value)

Default header line format.

Value: The styles to be injected into resulting html body.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setDefaultPageHeaderFormat(String value)

public final void setDefaultPageHeaderFormat(String value)

Default page header format.

Value: The styles to be injected into resulting html body.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setHtmlFormatOptions(int value)

public final void setHtmlFormatOptions(int value)

Gets or sets additional options when saving in HTML format. Default value is HtmlFormatOptions.None.

Parameters:

ParameterTypeDescription
valueint

setMailMessageSaveType(MailMessageSaveType value)

public final void setMailMessageSaveType(MailMessageSaveType value)

Represents the mail message save type.It can be in eml,msg(ASCII or Unicode),mhtml or html format. The default value is Eml.

Parameters:

ParameterTypeDescription
valueMailMessageSaveType

setRenderedContactFields(int value)

public final void setRenderedContactFields(int value)

Defines groups of Contact fields which will be included in output mhtml. Default value is ContactFieldsSet.AllExisting.

Parameters:

ParameterTypeDescription
valueint

setResourceHtmlRenderingHandler(ResourceHtmlRenderingHandler value)

public final void setResourceHtmlRenderingHandler(ResourceHtmlRenderingHandler value)

Provides customization of rendering resources in html.

Parameters:

ParameterTypeDescription
valueResourceHtmlRenderingHandler

setResourceRenderingMode(int value)

public final void setResourceRenderingMode(int value)

Provides set various modes of rendering resources in html. Default value EmbedIntoHtml.

Parameters:

ParameterTypeDescription
valueint

setUseRelativePathToResources(boolean value)

public final void setUseRelativePathToResources(boolean value)

If true then resources will be saved in folder htmlFileName.files in the same folder that html file and the relative path to resources will be added in html content , otherwise absolute path from ResourceHtmlRenderingEventArgs.PathToResourceFile property will be used for saving resources and adding to html. It make sense if ResourceRenderingMode is ResourceRenderingMode.SaveToFile. Default value is false.

Parameters:

ParameterTypeDescription
valueboolean

toString()

public String toString()

Returns: java.lang.String

wait()

public final void wait()

wait(long arg0)

public final native void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int