InboundEmail.TextAttachment Class
An InboundEmail object stores text attachments in an InboundEmail.TextAttachment object.
The text attachments can be any of the following:
-
Attachments with a Multipurpose Internet Mail Extension (MIME) type of
text -
Attachments with a MIME type of
application/octet-streamand a file name that ends with either a.vcfor.vcsextension. These are saved astext/x-vcardandtext/calendarMIME types, respectively.
The following are constructors for InboundEmail.TextAttachment.
-
Creates a new instance of the
Messaging.InboundEmail.TextAttachmentclass.
Creates a new instance of the Messaging.InboundEmail.TextAttachment class.
public InboundEmail.TextAttachment()
The following are properties for InboundEmail.TextAttachment.
-
The body of the attachment.
-
Indicates whether the attachment body text is truncated (
true) or not (false.) -
The original character set of the body field. The body is re-encoded as UTF-8 as input to the Apex method.
-
The name of the attached file.
-
Any header values associated with the attachment. Examples of header names include
Content-Type,Content-Transfer-Encoding, andContent-ID. -
The primary and sub MIME-type.
The body of the attachment.
public String body {get; set;}
Type: String
Indicates whether the attachment body text is truncated (true) or not (false.)
public Boolean bodyIsTruncated {get; set;}
Type: Boolean
The original character set of the body field. The body is re-encoded as UTF-8 as input to the Apex method.
public String charset {get; set;}
Type: String
The name of the attached file.
public String fileName {get; set;}
Type: String
Any header values associated with the attachment. Examples of header names include Content-Type, Content-Transfer-Encoding, and Content-ID.
public List<Messaging.InboundEmail.Header> headers {get; set;}
Type: List<Messaging.InboundEmail.Header>
The primary and sub MIME-type.
public String mimeTypeSubType {get; set;}
Type: String