
[Top]
MIME
MIME.Message
|
Class MIME.Message
- Description
-
This class is used to hold a decoded MIME message.
- Variable
headers
mapping(string:string) MIME.Message()->headers
- Description
-
This mapping contains all the headers of the message.
The key is the header name (in lower case) and the value is
the header value.
Although the mapping contains all headers, some particular headers get
special treatment by the module and should not be accessed through
this mapping. These fields are currently:
| "content-type" |
| "content-disposition" |
| "content-length" |
| "content-transfer-encoding" |
|
The contents of these fields can be accessed and/or modified through
a set of variables and methods available for this purpose.
- See also
type, subtype, charset, boundary, transfer_encoding,
params, disposition, disp_params, MIME.Message.setencoding,
MIME.Message.setparam, MIME.Message.setdisp_param, MIME.Message.setcharset, MIME.Message.setboundary
- Variable
body_parts
array(object) MIME.Message()->body_parts
- Description
-
If the message is of type multipart, this is an array
containing one Message object for each part of the message.
If the message is not a multipart, this field is 0 (zero).
- See also
type, boundary
- Variable
boundary
string MIME.Message()->boundary
- Description
-
For multipart messages, this Content-Type parameter gives a
delimiter string for separating the individual messages. As multiparts
are handled internally by the module, you should not need to access this
field.
- See also
MIME.Message.setboundary
- Variable
charset
string MIME.Message()->charset
- Description
-
One of the possible parameters of the <Content-Type header is the
charset attribute. It determines the character encoding used in bodies of
type text.
If there is no Content-Type header, the value of this field
is "us-ascii".
- See also
type
- Variable
type
string MIME.Message()->type
- Description
-
The Content-Type header contains a type, a subtype, and optionally
some parameters. This field contains the type attribute extracted
from the header.
If there is no Content-Type header, the value of this field
is "text".
- See also
subtype, params
- Variable
subtype
string MIME.Message()->subtype
- Description
-
The Content-Type header contains a type, a subtype, and optionally
some parameters. This field contains the subtype attribute extracted
from the header.
If there is no Content-Type header, the value of this field
is "plain".
- See also
type, params
- Variable
transfer_encoding
string MIME.Message()->transfer_encoding
- Description
-
The contents of the Content-Transfer-Encoding header.
If no Content-Transfer-Encoding header is given, this field
is 0 (zero).
Transfer encoding and decoding is done transparently by the module,
so this field should be interesting only to applications wishing to
do auto conversion of certain transfer encodings.
- See also
MIME.Message.setencoding
- Variable
params
mapping(string:string) MIME.Message()->params
- Description
-
A mapping containing all the additional parameters to the
Content-Type header.
Some of these parameters have fields of their own, which should
be accessed instead of this mapping wherever applicable.
- See also
charset, boundary, MIME.Message.setparam
- Variable
disposition
string MIME.Message()->disposition
- Description
-
The first part of the Content-Disposition header, hinting on how
this part of a multipart message should be presented in an interactive
application.
If there is no Content-Disposition header, this field
is 0.
- Variable
disp_params
mapping(string:string) MIME.Message()->disp_params
- Description
-
A mapping containing all the additional parameters to the
Content-Disposition header.
- See also
MIME.Message.setdisp_param, MIME.Message.get_filename
Extracted from Pike v7.3 release 11 at 2001-11-03.
|