org.jbpm.process.workitem.email
Class EmailWorkItemHandler
java.lang.Object
org.jbpm.process.workitem.email.EmailWorkItemHandler
- All Implemented Interfaces:
- WorkItemHandler
public class EmailWorkItemHandler
- extends Object
- implements org.drools.process.instance.WorkItemHandler
WorkItemHandler for sending email.
Expects the following parameters:
- "From" (String): sends an email from the given the email address
- "To" (String): sends the email to the given email address(es),
multiple addresses must be separated using a semi-colon (';')
- "Subject" (String): the subject of the email
- "Text" (String): the body of the email (using HTML)
Is completed immediately and does not return any result parameters.
Sending an email cannot be aborted.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EmailWorkItemHandler
public EmailWorkItemHandler()
EmailWorkItemHandler
public EmailWorkItemHandler(String host,
String port,
String userName,
String password)
setConnection
public void setConnection(String host,
String port,
String userName,
String password)
getConnection
public Connection getConnection()
executeWorkItem
public void executeWorkItem(WorkItem workItem,
WorkItemManager manager)
- Description copied from interface:
WorkItemHandler
- The given work item should be executed.
- Specified by:
executeWorkItem
in interface WorkItemHandler
- Parameters:
workItem
- the work item that should be executedmanager
- the manager that requested the work item to be executed
createEmail
protected static Email createEmail(WorkItem workItem,
Connection connection)
abortWorkItem
public void abortWorkItem(WorkItem arg0,
WorkItemManager arg1)
- Description copied from interface:
WorkItemHandler
- The given work item should be aborted.
- Specified by:
abortWorkItem
in interface WorkItemHandler
- Parameters:
arg0
- the work item that should be abortedarg1
- the manager that requested the work item to be aborted
Copyright © 2001-2012 JBoss by Red Hat. All Rights Reserved.