|
|
The BODY structure is a parsed form of a linked list of the MIME structure of a message. It contains the following information:
unsigned short type;
Body primary type code. This is an index into the body_types
vector of body type names. The following body types are pre-defined:
Additional types up to TYPEMAX are dynamically defined if they are encountered by a C client.
unsigned short encoding;
Body transfer encoding. This is an index into the body_encodings
vector of body encoding names. The following body encodings are pre-defined:
Additional encodings up to ENCMAX are dynamically defined if they are encountered by a C client.
char *subtype;
Body subtype string.
PARAMETER *parameter;
Parameter list.
char *id;
Body content identifier.
char *description;
Body content description.
unsigned char *contents.text;
When composing a message that is not of TYPEMULTIPART, non-binary text of the content is stored here. Note that this happens even when the text is of TYPEMESSAGE. Text of encoding ENC8BIT may be converted to ENCQUOTEDPRINTABLE when it is sent. This should not be referenced for any other reason; in particular, this is not the way for an application to access content data (use mail_fetchbody_full instead).
BINARY *contents.binary;
When composing a message that is not of TYPEMULTIPART, binary content (of encoding ENCBINARY) is stored here. It will be converted to ENCBASE64 when it is sent. This should not be referenced for any other reason; in particular, this is not the way for an application to access content data (use mail_fetchbody_full instead).
PART *contents.part;
For body parts of TYPEMULTIPART, this contains the list of body parts in this multipart.
MESSAGE contents.msg;
For body parts of TYPEMESSAGE with subtype RFC822, this contains the encapsulated message.
unsigned long size.lines;
Size in lines.
unsigned long size.bytes;
Size in octets; this must be set when composing a message if the encoding is ENC8BIT or ENCBINARY.
char *md5;
Body content MD5 checksum.
unsigned char *contents.text;
Drivers can store a pointer to the body contents as text here.
unsigned long size.ibytes;
Internal size of the body content (prior to newline conversion, and so on) in octets.