class documentation

class _MultipartMessageStructure(_MessageStructure): (source)

View In Hierarchy

_MultipartMessageStructure represents the message structure of a multipart/* message.
Method __init__
Method encode Encode each sub-message and added the additional multipart fields.
Instance Variable subtype Undocumented
Method _extended The extension data of a multipart body part are in the following order:
Method _getParts Return an iterator over all of the sub-messages of this message.

Inherited from _MessageStructure:

Instance Variable attrs Undocumented
Instance Variable message Undocumented
Method _disposition Parse a Content-Disposition header into a two-sequence of the disposition and a flattened list of its parameters.
Method _unquotedAttrs
def __init__(self, message, subtype, attrs): (source)
Parameters
messageAn IMessagePart provider which this structure object reports on.
subtypeA str giving the MIME subtype of the message (for example, "plain").
attrsA dict giving the parameters of the Content-Type header of the message.
def encode(self, extended): (source)
Encode each sub-message and added the additional multipart fields.
subtype = (source)

Undocumented

def _extended(self): (source)

The extension data of a multipart body part are in the following order:

  1. body parameter parenthesized list A parenthesized list of attribute/value pairs [e.g., ("foo" "bar" "baz" "rag") where "bar" is the value of "foo", and "rag" is the value of "baz"] as defined in [MIME-IMB].
  2. body disposition A parenthesized list, consisting of a disposition type string, followed by a parenthesized list of disposition attribute/value pairs as defined in [DISPOSITION].
  3. body language A string or parenthesized list giving the body language value as defined in [LANGUAGE-TAGS].
  4. body location A string list giving the body content URI as defined in [LOCATION].
def _getParts(self): (source)
Return an iterator over all of the sub-messages of this message.