uk.org.ogsadai.client.toolkit.activity.delivery
Class DeliverToSMTP

java.lang.Object
  |
  +--uk.org.ogsadai.client.toolkit.activity.RequestComponent
        |
        +--uk.org.ogsadai.client.toolkit.activity.Activity
              |
              +--uk.org.ogsadai.client.toolkit.activity.delivery.DeliverToSMTP

public class DeliverToSMTP
extends Activity

This activity creates and sends an e-mail containing data from another activity.

It has one input and no output.

Author:
The OGSA-DAI Project Team

Constructor Summary
DeliverToSMTP()
          Constructs a request to deliver data to SMTP.
DeliverToSMTP(java.util.List recipients, java.lang.String sender, java.lang.String subject, java.lang.String server)
          Constructs a request to deliver data to SMTP.
 
Method Summary
 void addRecipient(java.lang.String recipient)
          Add a recipient.
 void addRecipients(java.util.List recipients)
          Adds a list of recipients.
protected  java.lang.String generateXML()
          Generates the XML representing the activity.
 void setInput(ActivityOutput input)
          Sets the name of the output that will provide the specified input to this activity.
 void setRecipients(java.util.List recipients)
          Set the list of recipients.
 void setSender(java.lang.String sender)
          Set the sender.
 void setServer(java.lang.String server)
          Set the server.
 void setSubject(java.lang.String subject)
          Set the subject.
 
Methods inherited from class uk.org.ogsadai.client.toolkit.activity.Activity
addInput, addOutput, addOutputs, getDataResourceID, getDataServiceStub, getInputParameters, getOutputParameters, getOutputs, replaceSpecialCharacters, setDataResourceID, setDataServiceStub, setInput
 
Methods inherited from class uk.org.ogsadai.client.toolkit.activity.RequestComponent
getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeliverToSMTP

public DeliverToSMTP()
Constructs a request to deliver data to SMTP.


DeliverToSMTP

public DeliverToSMTP(java.util.List recipients,
                     java.lang.String sender,
                     java.lang.String subject,
                     java.lang.String server)
Constructs a request to deliver data to SMTP.

Parameters:
recipients - a list of Strings, which are e-mail addresses of recipients
Method Detail

setInput

public void setInput(ActivityOutput input)
Sets the name of the output that will provide the specified input to this activity.

Parameters:
input - input from another activity.
Throws:
java.lang.IllegalArgumentException - if the argument is null.

setRecipients

public void setRecipients(java.util.List recipients)
Set the list of recipients.

Parameters:
recipients - a list of Strings, which are e-mail addresses of recipients

addRecipient

public void addRecipient(java.lang.String recipient)
Add a recipient.

Parameters:
recipient - the e-mail address of the recipient

addRecipients

public void addRecipients(java.util.List recipients)
Adds a list of recipients.

Parameters:
recipients - a list of Strings, which are e-mail addresses of recipients

setSender

public void setSender(java.lang.String sender)
Set the sender.

Parameters:
sender - the e-mail address of the sender

setSubject

public void setSubject(java.lang.String subject)
Set the subject.

Parameters:
subject - the subject of the e-mail

setServer

public void setServer(java.lang.String server)
Set the server.

Parameters:
server - the address of the SMTP server, which must be listening on port 25

generateXML

protected java.lang.String generateXML()
Description copied from class: RequestComponent
Generates the XML representing the activity. This XML can then be inserted into a perform document that is sent to a data service.

Specified by:
generateXML in class Activity
Returns:
the XML for the activity
See Also:
Activity.generateXML()