Next: Quarantine functions, Previous: Mailbox functions, Up: Library [Contents][Index]
The functions described below retrieve information from RFC822
messages. The message to operate upon is identified by its
descriptor, an integer number returned by the previous call to
mailbox_get_message
(see mailbox_get_message) or current_message
(see current_message) function. The maximum number of message
descriptors is limited by 1024. You can change this limit
using the max-open-messages
runtime configuration statement
(see max-open-messages).
Return the size of the message nmsg, in bytes. Notice,
that if nmsg refers to current message
(see current_message), the returned value is less than the size
seen by the MTA, because mailfromd
recodes
CR-LF sequences to LF, i.e. removes carriage
returns (ASCII 13) occurring before line feeds
(ASCII 10. To obtain actual message length as seen by the
MTA, add the number of lines in the message:
set actual_length message_size(nmsg) + message_lines(nmsg)
Returns true
if the body of message nmsg has zero size or
contains only whitespace characters. If the
‘Content-Transfer-Encoding’ header is present, it is used to
decode body before processing.
Close the message identified by descriptor nmsg.
Return total number of lines in message nmsg. The following relation holds true:
message_lines(x) = message_body_lines(x) + message_header_lines(x) + 1
Read and return next line from the message nmsg. If
there are no more lines to read, raise the eof
exception.
Use message_rewind
to rewind the message stream and read its
contents again.
Rewind the stream associated with message referred to by descriptor nmsg.
Converts contents of the stream identified by fd to a mail message. Returns identifier of the created message.
Optional filter_chain supplies the name of a Mailutils filter chain, through which the data will be passed before converting. See http://mailutils.org/wiki/Filter_chain, for a description of filter chains.
Copies message nsmg to stream descriptor fd. The
descriptor must be obtained by a previous call to open
.
Optional filter_chain supplies the name of a Mailutils filter chain, through which the data will be passed before writing them to fd. See http://mailutils.org/wiki/Filter_chain, for a description of filter chains.
• Header functions | ||
• Message body functions | ||
• MIME functions | ||
• Message digest functions |
Next: Quarantine functions, Previous: Mailbox functions, Up: Library [Contents][Index]