public class EMailAlert
extends java.lang.Object
implements org.soafaces.bundle.workflow.Tasklet
This Tasklet sends email alerts and notifications. It can be used in a variety of ways by a Job. It can be used as the first Tasklet to inform the user that the Job has started processing or it can be used as the last Tasklet to inform the user that the Job has completed.
The customizer for this Tasklet allows the user to set the default values of the to/from/cc/subject/body of the email message. These properties can also be set dymically when the Job runs and thus passed in on the fly as input from another Tasklet. So you could dynmically set the email addresses or the body of the message as necessary from another Tasklet.
EMailAlertInput
Constructor and Description |
---|
EMailAlert() |
Modifier and Type | Method and Description |
---|---|
static Session |
createSession(java.lang.String stMailHost,
Authenticator smtpAuth,
int iMailPort,
int iMailSecurityType) |
Authenticator |
getSmtpAuthenticator() |
void |
onExecute(org.soafaces.bundle.workflow.TaskletInputContext inputContext,
org.soafaces.bundle.workflow.TaskletOutputContext outputContext)
Implement this method with virually any server-side code you want to execute.
|
public void onExecute(org.soafaces.bundle.workflow.TaskletInputContext inputContext, org.soafaces.bundle.workflow.TaskletOutputContext outputContext)
org.soafaces.bundle.workflow.Tasklet
Implement this method with virually any server-side code you want to execute. The container executing the Tasklet will invoke this method once the Tasklet is ready for execution.
A Tasklet can optionally use an input JavaBean as input to use during the execution of this method. The Tasklet can also store any relavent output that it wishes to expose or feed to other Tasklet, in the form of an output JavaBean, that execute later on in the workflow/job chain.
onExecute
in interface org.soafaces.bundle.workflow.Tasklet
inputContext
- This context contains information related to the input state the
Tasklet is running in.outputContext
- This context contains information related to the output state the
Tasklet is running in.public Authenticator getSmtpAuthenticator()
public static Session createSession(java.lang.String stMailHost, Authenticator smtpAuth, int iMailPort, int iMailSecurityType)
Copyright © Grand Logic, Inc. All Rights Reserved.