Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## jet.server.api.admin.cfg
Interface ConfigurationMail

    public interface ConfigurationMail

The `ConfigurationMail` interface provides the methods to configure the mail settings on JReport Server, including the mail sending related functions on JReport server, such as scheduling task of publishing to mail, and sending notification mail, etc.

Field Summary
`static int` | `SPLIT_BY_PAGE` SPLIT_BY_SIZE split PDF by page (1).
`static int` | `SPLIT_BY_SIZE` SPLIT_BY_SIZE split PDF by size (0).
`static java.lang.String` | `TAG_AUTHENTICATION` TAG_AUTHENTICATION tag to indicate whether the SMTP Server requires authentication ("smtp.authentication").
`static java.lang.String` | `TAG_AUTHENTICATION_PASSWORD` TAG_AUTHENTICATION_PASSWORD tag to indicate login password when SMTP server requires authentication ("smtp.password")
`static java.lang.String` | `TAG_AUTHENTICATION_USER` TAG_AUTHENTICATION_USER tag to indicate login user when SMTP server requires authentication ("smtp.user")
`static java.lang.String` | `TAG_COMPRESS` TAG_COMPRESS tag to indicate whether or not to compress the mail attachment as Java Archive ("compress.mail").
`static java.lang.String` | `TAG_DEFAULT_FORMAT` TAG_DEFAULT_FORMAT tag to indicate the default format of the e-mail ("default.format").
`static java.lang.String` | `TAG_MAIL_ENCODING` TAG_MAIL_ENCODING tag to indicate the encoding for notification E-mail title and comments ("mail.encoding")
`static java.lang.String` | `TAG_MAILBOX` TAG_MAILBOX tag to indicate the address of the e-mail sender, for the e-mail sent by JReport Server ("mailbox").
`static java.lang.String` | `TAG_MAXMAILPage` TAG_MAXMAILPage tag to indicate the maximum split page of the PDF attachment ("Tag_MaxMailPage"), which will take effect when the value of `TAG_SPLITBY` is `SPLIT_BY_PAGE`.
`static java.lang.String` | `TAG_MAXMAILSIZE` TAG_MAXMAILSIZE tag to indicate the maximum split size of the PDF attachment ("Tag_MaxMailSize"), which will take effect when the value of `TAG_SPLITBY` is `SPLIT_BY_SIZE`.
`static java.lang.String` | `TAG_SMTP_PORT` TAG_SMTP_PORT tag to indicate the port where the e-mail server runs ("smtp.server.port").
`static java.lang.String` | `TAG_SMTP_SERVER` TAG_SMTP_SERVER tag to indicate the numeric or named host of the machine where the e-mail server is located ("smtp.server").
`static java.lang.String` | `TAG_SPLITBY` TAG_SPLITBY tag to indicate whether to split PDF attachment by size or by page ("Tag_SplitBy").
`static java.lang.String` | `TAG_SSL` TAG_AUTHENTICATION tag to indicate whether the SMTP Server requires secure connection(SSL) ("smtp.SSL").

Method Summary
`boolean` | `getAuthentication()` Checks if SMTP server requires authentication for sending mails.
`java.lang.String` | `getAuthenticationPassword()` Get login password, which is used when `getAuthentication()` return true
`java.lang.String` | `getAuthenticationUser()` Get login user name, which is used when `getAuthentication()` return true
`int` | `getDefaultMailFormat()` Gets the format of the mail send out for scheduling of publishing to E-mail.
`boolean` | `getEnableCompress()` Checks whether to compress the mail attachment.
`java.lang.String` | `getEncoding()` Get the encoding for notification E-mail title and comments
`java.lang.String` | `getMailBox()` Returns the address of the mail sender, for the mails sent by JReport Server.
`java.util.Vector` | `getMailFormats()` Gets description of all the mail formats.
`int` | `getMailPort()` Returns the port of the SMTP mail server.
`java.lang.String` | `getMailServer()` Returns the name of the SMTP mail server.
`int` | `getMaxMailPage()` Gets the maximum page of the mail attachment in PDF format.
`int` | `getMaxMailSize()` Gets the maximum size of the mail attachment in PDF format.
`int` | `getSplitBy()` Gets the setting of splitting PDF attachment.
`boolean` | `getSSL()` Checks if SMTP server requires SSL for sending mails.
`void` | `setAuthentication(boolean isEnable)` Sets if the SMTP server requires authentication for sending mails.
`void` | `setAuthenticationPassword(java.lang.String pqssword)` Set login password, which is used when `getAuthentication()` return true
`void` | `setAuthenticationUser(java.lang.String username)` Set login user name, which is used when `getAuthentication()` return true
`void` | `setEnableCompress(boolean isEnable)` Sets whether to compress the mail attachment.
`void` | `setEncoding(java.lang.String encoding)` Set the encoding for notification E-mail title and comments
`void` | `setMailBox(java.lang.String mailBox)` Sets the address of the mail sender, for the mails sent by JReport Server.
`void` | `setMailFormat(int mailFormat)` Sets the default format of the mail send out for scheduling of publishing to E-mail.
`void` | `setMailPort(int port)` Sets the port of the SMTP mail server.
`void` | `setMailServer(java.lang.String smtpServerName)` Sets the name of the SMTP mail server.
`void` | `setMaxMailPage(int page)` Sets the maximum page of the mail attachment in PDF format.
`void` | `setMaxMailSize(int size)` Sets the maximum size of the mail attachment in PDF format.
`void` | `setSplitBy(int split)` Sets whether to split PDF attachment by size or by page.
`void` | `setSSL(boolean isEnable)` Sets if the SMTP server requires SSL for sending mails.

Field Detail

### TAG_SMTP_SERVER

    static final java.lang.String TAG_SMTP_SERVER

  TAG_SMTP_SERVER tag to indicate the numeric or named host of the machine where the e-mail server is located ("smtp.server").

  See Also:
    Constant Field Values

### TAG_SMTP_PORT

    static final java.lang.String TAG_SMTP_PORT

  TAG_SMTP_PORT tag to indicate the port where the e-mail server runs ("smtp.server.port").

  See Also:
    Constant Field Values

### TAG_AUTHENTICATION

    static final java.lang.String TAG_AUTHENTICATION

  TAG_AUTHENTICATION tag to indicate whether the SMTP Server requires authentication ("smtp.authentication").

  See Also:
    Constant Field Values

### TAG_AUTHENTICATION_USER

    static final java.lang.String TAG_AUTHENTICATION_USER

  TAG_AUTHENTICATION_USER tag to indicate login user when SMTP server requires authentication ("smtp.user")

  See Also:
    Constant Field Values

### TAG_AUTHENTICATION_PASSWORD

    static final java.lang.String TAG_AUTHENTICATION_PASSWORD

  TAG_AUTHENTICATION_PASSWORD tag to indicate login password when SMTP server requires authentication ("smtp.password")

  See Also:
    Constant Field Values

### TAG_MAIL_ENCODING

    static final java.lang.String TAG_MAIL_ENCODING

  TAG_MAIL_ENCODING tag to indicate the encoding for notification E-mail title and comments ("mail.encoding")

  See Also:
    Constant Field Values

### TAG_SSL

    static final java.lang.String TAG_SSL

  TAG_AUTHENTICATION tag to indicate whether the SMTP Server requires secure connection(SSL) ("smtp.SSL").

  See Also:
    Constant Field Values

### TAG_MAILBOX

    static final java.lang.String TAG_MAILBOX

  TAG_MAILBOX tag to indicate the address of the e-mail sender, for the e-mail sent by JReport Server ("mailbox").

  See Also:
    Constant Field Values

### TAG_DEFAULT_FORMAT

    static final java.lang.String TAG_DEFAULT_FORMAT

  TAG_DEFAULT_FORMAT tag to indicate the default format of the e-mail ("default.format").

  See Also:
    Constant Field Values

### TAG_COMPRESS

    static final java.lang.String TAG_COMPRESS

  TAG_COMPRESS tag to indicate whether or not to compress the mail attachment as Java Archive ("compress.mail").

  See Also:
    Constant Field Values

### TAG_MAXMAILSIZE

    static final java.lang.String TAG_MAXMAILSIZE

  TAG_MAXMAILSIZE tag to indicate the maximum split size of the PDF attachment ("Tag_MaxMailSize"), which will take effect when the value of `TAG_SPLITBY` is `SPLIT_BY_SIZE`.

  See Also:
    Constant Field Values

### TAG_MAXMAILPage

    static final java.lang.String TAG_MAXMAILPage

  TAG_MAXMAILPage tag to indicate the maximum split page of the PDF attachment ("Tag_MaxMailPage"), which will take effect when the value of `TAG_SPLITBY` is `SPLIT_BY_PAGE`.

  See Also:
    Constant Field Values

### TAG_SPLITBY

    static final java.lang.String TAG_SPLITBY

  TAG_SPLITBY tag to indicate whether to split PDF attachment by size or by page ("Tag_SplitBy").

  See Also:
    Constant Field Values

### SPLIT_BY_SIZE

    static final int SPLIT_BY_SIZE

  SPLIT_BY_SIZE split PDF by size (0).

  See Also:
    Constant Field Values

### SPLIT_BY_PAGE

    static final int SPLIT_BY_PAGE

  SPLIT_BY_SIZE split PDF by page (1).

  See Also:
    Constant Field Values

Method Detail

### setMailServer

    void setMailServer(java.lang.String smtpServerName)

  Sets the name of the SMTP mail server.

  Parameters:
    `smtpServerName` - the name of the SMTP mail server.

### getMailServer

    java.lang.String getMailServer()

  Returns the name of the SMTP mail server.

  Returns:
    the name of the SMTP mail server.

### setMailPort

    void setMailPort(int port)

  Sets the port of the SMTP mail server.

  Parameters:
    `port` - the port of the SMTP mail server.

### getMailPort

    int getMailPort()

  Returns the port of the SMTP mail server.

  Returns:
    the port of the SMTP mail server.

### setMailBox

    void setMailBox(java.lang.String mailBox)

  Sets the address of the mail sender, for the mails sent by JReport Server.

  Parameters:
    `mailBox` - the address of the mail sender.

### getMailBox

    java.lang.String getMailBox()

  Returns the address of the mail sender, for the mails sent by JReport Server.

  Returns:
    the address of the mail sender.

### setMailFormat

    void setMailFormat(int mailFormat)

  Sets the default format of the mail send out for scheduling of publishing to E-mail.

  Parameters:
    `mailFormat` - the format of the mail send out, the available values are: 0: E-mail Result in HTML E-mail Format, 1: E-mail Result in Plain Text E-mail Format, 2: Attachment in JReport Result Format, 3: Attachment in HTML Format, 4: Attachment in PDF Format, 5: Attachment in Excel Format, 6: Attachment in Text Format, 7: Attachment in RTF Format, 8: Attachment in XML Format, 9: Attachment in PostScript Format.

### getDefaultMailFormat

    int getDefaultMailFormat()

  Gets the format of the mail send out for scheduling of publishing to E-mail.

  Returns:
    the format of the mail send out, the available values are: 0: E-mail Result in HTML E-mail Format, 1: E-mail Result in Plain Text E-mail Format, 2: Attachment in JReport Result Format, 3: Attachment in HTML Format, 4: Attachment in PDF Format, 5: Attachment in Excel Format, 6: Attachment in Text Format, 7: Attachment in RTF Format, 8: Attachment in XML Format, 9: Attachment in PostScript Format.

### getMailFormats

    java.util.Vector getMailFormats()

  Gets description of all the mail formats.

  Returns:
    vector in which all the mail formats, contains the strings below to represent every mail format: "E-mail Result in HTML E-mail Format", "E-mail Result in Plain Text E-mail Format", "Attachment in JReport Result Format", "Attachment in HTML Format", "Attachment in PDF Format", "Attachment in Excel Format", "Attachment in Text Format", "Attachment in RTF Format", "Attachment in XML Format", "Attachment in PostScript Format".

### setEnableCompress

    void setEnableCompress(boolean isEnable)

  Sets whether to compress the mail attachment.

  Parameters:
    `isEnable` - if true, the mail will be compressed; if false, will not be.

### getEnableCompress

    boolean getEnableCompress()

  Checks whether to compress the mail attachment.

  Returns:
    true if the mail is compressed, otherwise false.

### setMaxMailSize

    void setMaxMailSize(int size)

  Sets the maximum size of the mail attachment in PDF format. The size will take effect when the method `setSplitBy()` is invoked and parameter value is `SPLIT_BY_SIZE`.

  Parameters:
    `size` - the maximum size of the mail attachment in PDF format.

### getMaxMailSize

    int getMaxMailSize()

  Gets the maximum size of the mail attachment in PDF format.

  Returns:
    the maximum size of the mail attachment in PDF format.

### setMaxMailPage

    void setMaxMailPage(int page)

  Sets the maximum page of the mail attachment in PDF format. The value will take effect when the method `setSplitBy()` is invoked and parameter value is `SPLIT_BY_PAGE`.

  Parameters:
    `page` - the maximum page of the mail attachment in PDF format.

### getMaxMailPage

    int getMaxMailPage()

  Gets the maximum page of the mail attachment in PDF format.

  Returns:
    the maximum page of the mail attachment in PDF format.

### setSplitBy

    void setSplitBy(int split)

  Sets whether to split PDF attachment by size or by page. By default, JReport Server splits PDF attachment by size and the maximum size is unlimited.

  Parameters:
    `split` - indicates whether to split PDF by size or by page. `SPLIT_BY_SIZE(0)` means to split by size, `SPLIT_BY_PAGE(1)` means to split by page.

### getSplitBy

    int getSplitBy()

  Gets the setting of splitting PDF attachment. By default, JReport Server splits PDF attachment by size and the maximum size is unlimited.

  Returns:
    setting of splitting PDF by size or by page. `SPLIT_BY_SIZE(0)` means to split by size, `SPLIT_BY_PAGE(1)` means to split by page.

### setAuthentication

    void setAuthentication(boolean isEnable)

  Sets if the SMTP server requires authentication for sending mails. If it is set to true, JReport Server will let you input authentication information in the Schedule > Publish > To E-mail page.

  Parameters:
    `isEnable` - if the SMTP server requires authentication for sending mails.

### getAuthentication

    boolean getAuthentication()

  Checks if SMTP server requires authentication for sending mails.

  Returns:
    true if SMTP server requires authentication for sending mails, otherwise return false.

### setSSL

    void setSSL(boolean isEnable)

  Sets if the SMTP server requires SSL for sending mails.

  Parameters:
    `isEnable` - if the SMTP server requires SSL for sending mails.

### getSSL

    boolean getSSL()

  Checks if SMTP server requires SSL for sending mails.

  Returns:
    true if SMTP server requires SSL for sending mails, otherwise return false.

### getEncoding

    java.lang.String getEncoding()

  Get the encoding for notification E-mail title and comments

  Returns:
    encoding

### setEncoding

    void setEncoding(java.lang.String encoding)

  Set the encoding for notification E-mail title and comments

  Parameters:
    `encoding` - encoding that want to set

### getAuthenticationUser

    java.lang.String getAuthenticationUser()

  Get login user name, which is used when `getAuthentication()` return true

  Returns:
    login user name

### setAuthenticationUser

    void setAuthenticationUser(java.lang.String username)

  Set login user name, which is used when `getAuthentication()` return true

  Parameters:
    `username` - login user name.

### getAuthenticationPassword

    java.lang.String getAuthenticationPassword()

  Get login password, which is used when `getAuthentication()` return true

  Returns:
    login password

### setAuthenticationPassword

    void setAuthenticationPassword(java.lang.String pqssword)

  Set login password, which is used when `getAuthentication()` return true

  Parameters:
    `pqssword` - login password

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD