Sming Framework API
Sming - Open Source framework for high efficiency WiFi SoC ESP8266 native development with C++ language.
MailMessage Class Reference

Public Member Functions

MailMessagesetHeader (const String &name, const String &value)
 
HttpHeadersgetHeaders ()
 
MailMessagesetBody (const String &body, MimeType mime=MIME_TEXT)
 Sets the body of the email. More...
 
MailMessagesetBody (IDataSourceStream *stream, MimeType mime=MIME_TEXT)
 Sets the body of the email. More...
 
MailMessageaddAttachment (FileStream *stream)
 Adds attachment to the email. More...
 
MailMessageaddAttachment (IDataSourceStream *stream, MimeType mime, const String &filename="")
 Adds attachment to the email. More...
 
MailMessageaddAttachment (IDataSourceStream *stream, const String &mime, const String &filename="")
 Adds attachment to the email. More...
 

Public Attributes

String to
 
String from
 
String subject
 
String cc
 

Friends

class SmtpClient
 

Member Function Documentation

MailMessage& MailMessage::addAttachment ( FileStream stream)

Adds attachment to the email.

MailMessage& MailMessage::addAttachment ( IDataSourceStream stream,
MimeType  mime,
const String filename = "" 
)

Adds attachment to the email.

MailMessage& MailMessage::addAttachment ( IDataSourceStream stream,
const String mime,
const String filename = "" 
)

Adds attachment to the email.

MailMessage& MailMessage::setBody ( const String body,
MimeType  mime = MIME_TEXT 
)

Sets the body of the email.

Parameters
Stringbody
MimeTypemime
MailMessage& MailMessage::setBody ( IDataSourceStream stream,
MimeType  mime = MIME_TEXT 
)

Sets the body of the email.

Parameters
Stream&stream
MimeTypemime