IEmail.Message

public static class IEmail.Message
extends Object

java.lang.Object
   ↳ com.android.tradefed.util.IEmail.Message


Container for email message data.

Summary

Constants

String HTML

String PLAIN

Public constructors

IEmail.Message()
IEmail.Message(String to, String subject, String body)

Convenience constructor: create a simple message

Public methods

void addBcc(String address)
void addCc(String address)
void addTo(String address)
Collection<String> getBcc()
String getBody()
Collection<String> getCc()
String getContentType()
String getSender()
String getSubject()
Collection<String> getTo()
boolean isHtml()
void setBody(String body)
void setContentType(String contentType)
void setHtml(boolean html)
void setSender(String sender)
void setSubject(String subject)
void setTos(String[] recipients)

Set the recipients.

Constants

HTML

static final String HTML

Constant Value: "text/html"

PLAIN

static final String PLAIN

Constant Value: "text/plain"

Public constructors

IEmail.Message

public IEmail.Message ()

IEmail.Message

public IEmail.Message (String to, 
                String subject, 
                String body)

Convenience constructor: create a simple message

Parameters
to String: Single destination address

subject String: Subject

body String: Message body

Public methods

addBcc

public void addBcc (String address)

Parameters
address String

addCc

public void addCc (String address)

Parameters
address String

addTo

public void addTo (String address)

Parameters
address String

getBcc

public Collection<String> getBcc ()

Returns
Collection<String>

getBody

public String getBody ()

Returns
String

getCc

public Collection<String> getCc ()

Returns
Collection<String>

getContentType

public String getContentType ()

Returns
String

getSender

public String getSender ()

Returns
String

getSubject

public String getSubject ()

Returns
String

getTo

public Collection<String> getTo ()

Returns
Collection<String>

isHtml

public boolean isHtml ()

Returns
boolean

setBody

public void setBody (String body)

Parameters
body String

setContentType

public void setContentType (String contentType)

Parameters
contentType String

setHtml

public void setHtml (boolean html)

Parameters
html boolean

setSender

public void setSender (String sender)

Parameters
sender String

setSubject

public void setSubject (String subject)

Parameters
subject String

setTos

public void setTos (String[] recipients)

Set the recipients. All previously added recipients will be replaced. addTo(String) to append to the recipients list.

Parameters
recipients String: an array of recipient email addresses