Trees | Indices | Help |
|
---|
Address parser class by Ben Escoto.
To understand what this class does, it helps to have a copy of RFC 2822 in front of you.
Note: this class interface is deprecated and may be removed in the future. Use rfc822.AddressList instead.
Initialize a new instance.
`field' is an unparsed address header field, containing one or more addresses.
Parse all addresses.
Returns a list containing all of the addresses.
Parse a route address (Return-path value).
This method just skips all the route stuff and returns the addrspec.
Parse a header fragment delimited by special characters.
`beginchar' is the start character for the fragment. If self is not looking at an instance of `beginchar' then getdelimited returns the empty string.
`endchars' is a sequence of allowable end-delimiting characters. Parsing stops when one of these is encountered.
If `allowcomments' is non-zero, embedded RFC 2822 comments are allowed within the parsed fragment.
Parse an RFC 2822 atom.
Optional atomends specifies a different set of end token delimiters (the default is to use self.atomends). This is used e.g. in getphraselist() since phrase endings must not include the `.' (which is legal in phrases).
Parse a sequence of RFC 2822 phrases.
A phrase is a sequence of words, which are in turn either RFC 2822 atoms or quoted-strings. Phrases are canonicalized by squeezing all runs of continuous whitespace into one space.
Trees | Indices | Help |
|
---|