org.jtheque.utils.bean
Class Email

java.lang.Object
  extended by org.jtheque.utils.bean.Email

public final class Email
extends Object

An email.

Author:
Baptiste Wicht

Constructor Summary
Email()
           
 
Method Summary
 void attachFile(File f)
          Attach a file to the mail.
 void attachFiles(Collection<File> c)
          Attach files to the mail.
 Collection<File> getAttachedFiles()
          Return the files attached to the mail.
 String getFrom()
          Return the from address.
 String getMessage()
          Return the message.
 String getSubject()
          Return the subject.
 String[] getTo()
          Return the to addresses.
 void setFrom(String from)
          Set the from address.
 void setMessage(String message)
          Set the message.
 void setSubject(String subject)
          Set the subject.
 void setTo(String[] to)
          Set the addresses to.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Email

public Email()
Method Detail

getFrom

public String getFrom()
Return the from address.

Returns:
The address from.

setFrom

public void setFrom(String from)
Set the from address.

Parameters:
from - The from address.

getMessage

public String getMessage()
Return the message.

Returns:
The message.

setMessage

public void setMessage(String message)
Set the message.

Parameters:
message - The message to set.

getSubject

public String getSubject()
Return the subject.

Returns:
The subject.

setSubject

public void setSubject(String subject)
Set the subject.

Parameters:
subject - The subject.

getTo

public String[] getTo()
Return the to addresses.

Returns:
A array of String containing all the addresses to.

setTo

public void setTo(String[] to)
Set the addresses to.

Parameters:
to - An array containing all the destination addresses.

attachFile

public void attachFile(File f)
Attach a file to the mail.

Parameters:
f - The file to attach.

attachFiles

public void attachFiles(Collection<File> c)
Attach files to the mail.

Parameters:
c - The collection of files to attach to the mail.

getAttachedFiles

public Collection<File> getAttachedFiles()
Return the files attached to the mail.

Returns:
A List containing all the files attached to the mail.


Copyright © 2010 JTheque. All Rights Reserved.