1998-08-10 16:42:37 -03:00
|
|
|
\section{\module{mailbox} ---
|
1999-02-20 01:04:59 -04:00
|
|
|
Read various mailbox formats}
|
1998-07-23 14:59:49 -03:00
|
|
|
|
1999-02-20 01:04:59 -04:00
|
|
|
\declaremodule{standard}{mailbox}
|
1998-07-23 14:59:49 -03:00
|
|
|
\modulesynopsis{Read various mailbox formats.}
|
|
|
|
|
1997-06-02 18:04:41 -03:00
|
|
|
|
|
|
|
This module defines a number of classes that allow easy and uniform
|
1998-03-14 02:48:33 -04:00
|
|
|
access to mail messages in a (\UNIX{}) mailbox.
|
1997-06-02 18:04:41 -03:00
|
|
|
|
1998-03-14 02:48:33 -04:00
|
|
|
\begin{classdesc}{UnixMailbox}{fp}
|
1998-01-13 15:01:57 -04:00
|
|
|
Access a classic \UNIX{}-style mailbox, where all messages are contained
|
1998-02-13 18:17:21 -04:00
|
|
|
in a single file and separated by ``From name time'' lines.
|
|
|
|
The file object \var{fp} points to the mailbox file.
|
1998-03-14 02:48:33 -04:00
|
|
|
\end{classdesc}
|
1997-06-02 18:04:41 -03:00
|
|
|
|
1998-03-14 02:48:33 -04:00
|
|
|
\begin{classdesc}{MmdfMailbox}{fp}
|
1997-06-02 18:04:41 -03:00
|
|
|
Access an MMDF-style mailbox, where all messages are contained
|
|
|
|
in a single file and separated by lines consisting of 4 control-A
|
1998-02-13 18:17:21 -04:00
|
|
|
characters. The file object \var{fp} points to the mailbox file.
|
1998-03-14 02:48:33 -04:00
|
|
|
\end{classdesc}
|
1997-06-02 18:04:41 -03:00
|
|
|
|
1998-03-14 02:48:33 -04:00
|
|
|
\begin{classdesc}{MHMailbox}{dirname}
|
1997-06-02 18:04:41 -03:00
|
|
|
Access an MH mailbox, a directory with each message in a separate
|
1998-02-13 18:17:21 -04:00
|
|
|
file with a numeric name.
|
|
|
|
The name of the mailbox directory is passed in \var{dirname}.
|
1998-03-14 02:48:33 -04:00
|
|
|
\end{classdesc}
|
1997-06-02 18:04:41 -03:00
|
|
|
|
1999-02-20 01:04:59 -04:00
|
|
|
\begin{classdesc}{Maildir}{dirname}
|
|
|
|
Access a Qmail mail directory. All new and current mail for the
|
|
|
|
mailbox specified by \var{dirname} is made available.
|
|
|
|
\end{classdesc}
|
|
|
|
|
|
|
|
\begin{classdesc}{BabylMailbox}{fp}
|
|
|
|
Access a Babyl mailbox, which is similar to an MMDF mailbox. Mail
|
1999-02-22 09:45:09 -04:00
|
|
|
messages start with a line containing only \code{'*** EOOH ***'} and
|
1999-02-22 10:26:16 -04:00
|
|
|
end with a line containing only \code{'\e{}037\e{}014'}.
|
1999-02-20 01:04:59 -04:00
|
|
|
\end{classdesc}
|
|
|
|
|
|
|
|
|
|
|
|
\subsection{Mailbox Objects \label{mailbox-objects}}
|
1997-06-02 18:04:41 -03:00
|
|
|
|
|
|
|
All implementations of Mailbox objects have one externally visible
|
|
|
|
method:
|
|
|
|
|
1998-04-02 14:50:21 -04:00
|
|
|
\begin{methoddesc}[mailbox]{next}{}
|
1999-03-27 01:45:46 -04:00
|
|
|
Return the next message in the mailbox, as a \class{rfc822.Message}
|
|
|
|
object (see the \refmodule{rfc822} module). Depending on the mailbox
|
|
|
|
implementation the \var{fp} attribute of this object may be a true
|
|
|
|
file object or a class instance simulating a file object, taking care
|
|
|
|
of things like message boundaries if multiple mail messages are
|
1997-06-02 18:04:41 -03:00
|
|
|
contained in a single file, etc.
|
1998-04-02 14:50:21 -04:00
|
|
|
\end{methoddesc}
|