org.springframework.integration.adapter.mail
Class StaticMailHeaderGenerator

java.lang.Object
  extended by org.springframework.integration.adapter.mail.AbstractMailHeaderGenerator
      extended by org.springframework.integration.adapter.mail.StaticMailHeaderGenerator
All Implemented Interfaces:
MailHeaderGenerator

public class StaticMailHeaderGenerator
extends AbstractMailHeaderGenerator

Mail header generator implementation that populates a mail message header from statically configured properties.

Author:
Marius Bogoevici

Constructor Summary
StaticMailHeaderGenerator()
           
 
Method Summary
protected  java.lang.String[] getBcc(org.springframework.integration.message.Message<?> message)
          Retrieve the BCC recipients list from an integration message.
protected  java.lang.String[] getCc(org.springframework.integration.message.Message<?> message)
          Retrieve the CC recipients list from an integration message.
protected  java.lang.String getFrom(org.springframework.integration.message.Message<?> message)
          Retrieve the From: e-mail address from an integration message.
protected  java.lang.String getReplyTo(org.springframework.integration.message.Message<?> message)
          Retrieve the Reply To: e-mail address from an integration message.
protected  java.lang.String getSubject(org.springframework.integration.message.Message<?> message)
          Retrieve the subject of an e-mail message from an integration message.
protected  java.lang.String[] getTo(org.springframework.integration.message.Message<?> message)
          Retrieve the recipients list from an integration message.
 void setBcc(java.lang.String[] bcc)
           
 void setCc(java.lang.String[] cc)
           
 void setFrom(java.lang.String from)
           
 void setReplyTo(java.lang.String replyTo)
           
 void setSubject(java.lang.String subject)
           
 void setTo(java.lang.String[] to)
           
 
Methods inherited from class org.springframework.integration.adapter.mail.AbstractMailHeaderGenerator
populateMailMessageHeader
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticMailHeaderGenerator

public StaticMailHeaderGenerator()
Method Detail

setSubject

public void setSubject(java.lang.String subject)

getSubject

protected java.lang.String getSubject(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the subject of an e-mail message from an integration message.

Specified by:
getSubject in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
the e-mail message subject

setTo

public void setTo(java.lang.String[] to)

getTo

protected java.lang.String[] getTo(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the recipients list from an integration message.

Specified by:
getTo in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
recipients list (TO)

setCc

public void setCc(java.lang.String[] cc)

getCc

protected java.lang.String[] getCc(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the CC recipients list from an integration message.

Specified by:
getCc in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
CC recipients list (e-mail addresses)

setBcc

public void setBcc(java.lang.String[] bcc)

getBcc

protected java.lang.String[] getBcc(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the BCC recipients list from an integration message.

Specified by:
getBcc in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
BCC recipients list (e-mail addresses)

setFrom

public void setFrom(java.lang.String from)

getFrom

protected java.lang.String getFrom(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the From: e-mail address from an integration message.

Specified by:
getFrom in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
the From: e-mail address

setReplyTo

public void setReplyTo(java.lang.String replyTo)

getReplyTo

protected java.lang.String getReplyTo(org.springframework.integration.message.Message<?> message)
Description copied from class: AbstractMailHeaderGenerator
Retrieve the Reply To: e-mail address from an integration message.

Specified by:
getReplyTo in class AbstractMailHeaderGenerator
Parameters:
message - the integration Message
Returns:
the ReplyTo: e-mail address