Ensures that a mail context is present within the current pageContext. This tag must appear, at least once, before all other tags within the Mail taglib. If config is not specified, then a search for a useable configuration name is performed in the following fashion:Attempt to retrieve the current mail configuration name from the page context. If that succeeds, use it. If the retrieval fails... Attempt to retrieve the current mail configuration name from the session. If that succeeds, store it on the page context and use it. If the retrieval fails... From the list of all SSOAdapter configuration names, try to find the first useable mail configuration name. If that succeeds, store it in the session and page context and use it. If it is not possible to find a useable mail configuration name, the context tag will fail.Once a configuration name has been determined, an attempt is made to acquire an appropriate mail context object. This is done in the following fashion:Attempt to retrieve a mail context from the page context, and verify it matches the configuration (using the previously acquired configuration name). If that succeeds, use it. If that fails... Attempt to retrieve a mail context from the user's cache of mail contexts. If that succeeds, store it on the page context and use it. If the retrieval fails... Create an SSOAdapter object using the previously acquired configuration name. Create a mail context, and bind it with the SSOAdapter object. Store the mail context in the context cache as well as the page context.In this way, if a mail context has been previously referenced on a page, or within the session, then the config attribute may be omitted, and the most recently referenced context will be retrieved.
JSP or Empty
None.
The tag has the following attributes for which the Required value is “No”:
Specifies the "configuration" for which a mail context should be retrieved.
Permits testing of service availability. Operates according to the following table:
Evaluate tag body when test = true and Skip tag body when test = false.
Skip tag body when test = true and Evaluate tag body when test = false.
The tag provides the following bean properties for which for which the Type values are “String”, “Integer” and “Boolean” and the Access value is “Get”:
Indicates the error code in case the execution of a command tag fails. Possible values:
Empty error code indicates a generic tag execution failed error.
MAIL_001 - Unable to send message because of Invalid email address.
MAIL_002 - Unable to send message.
MAIL_003 - Attempt to create a folder that already exists.
MAIL_004 - Failed to create folder.
Number of messages in the INBOX.
Number of unread messages in the INBOX.
Number of new messages in the INBOX.
Number of messages in the current folder.
Number of unread messages in the current folder.
Number of new messages in the current folder.
User's predefined signature.
A boolean that indicates if there is a message following the message from which was fetched the current lines collection.
A boolean that indicates if there is a message prior to the message from which was fetched the current lines collection.
The index of the message following the message from which was fetched the current lines collection.
The index of the message prior to the message from which was fetched the current lines collection.
A boolean that indicates whether or not the user has any predefined messages.
A boolean that indicates whether or not to include the original message within a reply message.
A boolean that indicates whether or not to append the user's signature onto an outgoing message sent with sendmessage.
<%-- example of context tag usage --%> <mail:context> ... <mail:context> <p>New Message: <mail:get property="inboxNumNewMsgs"/> </mail:context>