mirror of
https://github.com/python/cpython.git
synced 2025-07-24 03:35:53 +00:00
body_line_iterator() now takes a decode argument.
This commit is contained in:
parent
08898499b2
commit
52b39f5b47
1 changed files with 3 additions and 1 deletions
|
@ -6,13 +6,15 @@ Iterating over a message object tree is fairly easy with the
|
|||
provides some useful higher level iterations over message object
|
||||
trees.
|
||||
|
||||
\begin{funcdesc}{body_line_iterator}{msg}
|
||||
\begin{funcdesc}{body_line_iterator}{msg\optional{, decode}}
|
||||
This iterates over all the payloads in all the subparts of \var{msg},
|
||||
returning the string payloads line-by-line. It skips over all the
|
||||
subpart headers, and it skips over any subpart with a payload that
|
||||
isn't a Python string. This is somewhat equivalent to reading the
|
||||
flat text representation of the message from a file using
|
||||
\method{readline()}, skipping over all the intervening headers.
|
||||
|
||||
Optional \var{decode} is passed through to \method{Message.get_payload()}.
|
||||
\end{funcdesc}
|
||||
|
||||
\begin{funcdesc}{typed_subpart_iterator}{msg\optional{,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue