Package org.apache.commons.mail2.core
Class EmailConstants
java.lang.Object
org.apache.commons.mail2.core.EmailConstants
Constants used by Email classes.
A description of the mail session parameter you find at
https://java.sun.com/products/javamail/javadocs/com/sun/mail/smtp/package-summary.html.
- Since:
- 1.3
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringCharset constant for iso-8859-1static final StringCharset constant for koi8-rstatic final StringThe debug mode to be used.static final StringThe from email address.static final StringThe host name of the mail server.static final StringDefines the default mime charset to use when none has been specified for the message.static final StringThe port number of the mail server.static final StringIf set to true, tries to authenticate the user using the AUTH command.static final StringSocket connection timeout value in milliseconds.static final StringThe email address to use for SMTP MAIL command.static final StringThe SMTP password.static final StringIf set to true, and a message has some valid and some invalid addresses, send the message anyway, reporting the partial failure with a SendFailedException.static final StringSpecifies theSocketFactoryclass to create smtp sockets.static final StringWhether to useSocketas a fallback if the initial connection fails or not.static final StringSpecifies the port to connect to when using a socket factory.static final StringIf set to true, check the server identity as specified in RFC 2595.static final StringIf set to true, use SSL to connect and use the SSL port by default.static final StringSpecifies theSSLSocketFactoryclass to use to create SMTP SSL sockets.static final StringSpecifies the port to connect to when using the SMTP SSL socket factory.static final StringSocket I/O timeout value in milliseconds.static final StringThe SMTP user name.static final StringIf set to true, and a message has some valid and some invalid addresses, send the message anyway, reporting the partial failure with a SendFailedException.static final StringSpecifies the default transport protocolstatic final StringIndicates if the STARTTLS command shall be used to initiate a TLS-secured connection.static final StringIf true, requires the use of the STARTTLS command.static final StringThe value to use SMTP as transport protocolstatic final DurationDefault socket timeout.static final StringDefines the text/html content typestatic final StringDefines the text/plain content typestatic final StringDefines the html subtypestatic final StringCharset constant for us-asciistatic final StringCharset constant for utf-8 -
Method Summary
-
Field Details
-
KOI8_R
Charset constant for koi8-r- See Also:
-
ISO_8859_1
Charset constant for iso-8859-1 -
US_ASCII
Charset constant for us-ascii -
UTF_8
Charset constant for utf-8 -
MAIL_DEBUG
The debug mode to be used.- See Also:
-
MAIL_HOST
The host name of the mail server.- See Also:
-
MAIL_PORT
The port number of the mail server.- See Also:
-
MAIL_SMTP_FROM
The email address to use for SMTP MAIL command.- See Also:
-
MAIL_SMTP_AUTH
If set to true, tries to authenticate the user using the AUTH command.- See Also:
-
MAIL_SMTP_USER
The SMTP user name.- See Also:
-
MAIL_SMTP_PASSWORD
The SMTP password.- See Also:
-
MAIL_TRANSPORT_PROTOCOL
Specifies the default transport protocol- See Also:
-
SMTP
The value to use SMTP as transport protocol- See Also:
-
TEXT_HTML
Defines the text/html content type- See Also:
-
TEXT_SUBTYPE_HTML
Defines the html subtype- See Also:
-
TEXT_PLAIN
Defines the text/plain content type- See Also:
-
MAIL_TRANSPORT_STARTTLS_ENABLE
Indicates if the STARTTLS command shall be used to initiate a TLS-secured connection.- Since:
- 1.1
- See Also:
-
MAIL_SMTP_SOCKET_FACTORY_FALLBACK
Whether to useSocketas a fallback if the initial connection fails or not.- Since:
- 1.1
- See Also:
-
MAIL_SMTP_SOCKET_FACTORY_CLASS
Specifies theSocketFactoryclass to create smtp sockets.- Since:
- 1.1
- See Also:
-
MAIL_SMTP_SOCKET_FACTORY_PORT
Specifies the port to connect to when using a socket factory.- Since:
- 1.1
- See Also:
-
MAIL_SMTP_CONNECTIONTIMEOUT
Socket connection timeout value in milliseconds. Default is infinite timeout.- Since:
- 1.2
- See Also:
-
MAIL_SMTP_TIMEOUT
Socket I/O timeout value in milliseconds. Default is infinite timeout.- Since:
- 1.2
- See Also:
-
SOCKET_TIMEOUT
Default socket timeout.- Since:
- 1.6.0
-
MAIL_TRANSPORT_STARTTLS_REQUIRED
If true, requires the use of the STARTTLS command. If the server doesn't support the STARTTLS command, the connection will fail.- Since:
- 1.3
- See Also:
-
MAIL_SMTP_SSL_ENABLE
If set to true, use SSL to connect and use the SSL port by default.- Since:
- 1.3
- See Also:
-
MAIL_SMTP_SSL_CHECKSERVERIDENTITY
If set to true, check the server identity as specified in RFC 2595.- Since:
- 1.3
- See Also:
-
MAIL_SMTP_SSL_SOCKET_FACTORY_CLASS
Specifies theSSLSocketFactoryclass to use to create SMTP SSL sockets.- Since:
- 1.3
- See Also:
-
MAIL_SMTP_SSL_SOCKET_FACTORY_PORT
Specifies the port to connect to when using the SMTP SSL socket factory.- Since:
- 1.3
- See Also:
-
MAIL_SMTP_SEND_PARTIAL
If set to true, and a message has some valid and some invalid addresses, send the message anyway, reporting the partial failure with a SendFailedException. If set to false (the default), the message is not sent to any of the recipients if there is an invalid recipient address.- Since:
- 1.3.2
- See Also:
-
MAIL_SMTPS_SEND_PARTIAL
If set to true, and a message has some valid and some invalid addresses, send the message anyway, reporting the partial failure with a SendFailedException. If set to false (the default), the message is not sent to any of the recipients if there is an invalid recipient address.- Since:
- 1.3.2
- See Also:
-
MAIL_MIME_CHARSET
Defines the default mime charset to use when none has been specified for the message.- Since:
- 1.3.2
- See Also:
-
MAIL_FROM
The from email address.- Since:
- 1.4
- See Also:
-