MimeMultipartBody Class Reference
MIME multipart container.
More...
#include <yatemime.h>
List of all members.
Detailed Description
MIME multipart container.
An object holding the bodies of a multipart MIME
Constructor & Destructor Documentation
MimeMultipartBody |
( |
const char * |
subtype = "mixed" , |
|
|
const char * |
boundary = 0 | |
|
) |
| | [explicit] |
Constructor to build an empty multipart body
- Parameters:
-
| subtype | The multipart subtype |
| boundary | The string used as separator for enclosed bodies. A random one will be created if missing. The length will be truncated to 70 if this value is exceeded |
Constructor from block of data
- Parameters:
-
| type | The value of the Content-Type header line |
| buf | Pointer to buffer of data |
| len | Length of data in buffer |
Constructor from block of data
- Parameters:
-
| type | The content type header line |
| buf | Pointer to buffer of data |
| len | Length of data in buffer |
Member Function Documentation
const ObjList& bodies |
( |
|
) |
const [inline] |
Get the list of bodies enclosed contained in this multipart
- Returns:
- The list of bodies enclosed contained in this multipart
void appendBody |
( |
MimeBody * |
body |
) |
[inline] |
Append a body to this multipart
- Parameters:
-
void removeBody |
( |
MimeBody * |
body, |
|
|
bool |
delobj = true | |
|
) |
| | [inline] |
Remove a body from this multipart
- Parameters:
-
| body | The body to remove |
| delobj | True to delete the body, false to remove from list without deleting it |
Find a body. Enclosed multiparts are also searched for the requested body
- Parameters:
-
| content | The value of the body to find. Must be lower case |
| start | The starting point in the list. 0 to start from the beginning. Be aware that this parameter is used internally to search within enclosed multipart bodies and set to 0 when the starting point is found |
- Returns:
- Pointer to MimeBody or 0 if not found
virtual void* getObject |
( |
const String & |
name |
) |
const [virtual] |
RTTI method, get a pointer to a derived class given the class name
- Parameters:
-
| name | Name of the class we are asking for |
- Returns:
- Pointer to the requested class or NULL if this object doesn't implement it
Reimplemented from MimeBody.
virtual bool isMultipart |
( |
|
) |
const [inline, virtual] |
Check if this body is multipart (can hold other MIME bodies)
- Returns:
- True if this body is multipart
Reimplemented from MimeBody.
virtual MimeBody* clone |
( |
|
) |
const [virtual] |
Duplicate this MIME body
- Returns:
- Copy of this MIME body
Implements MimeBody.
virtual void buildBody |
( |
|
) |
const [protected, virtual] |
Method that is called internally to build the binary encoded body
Implements MimeBody.
void parse |
( |
const char * |
buf, |
|
|
int |
len | |
|
) |
| | [protected] |
Parse a data buffer and append any valid body to this multipart Ignore prolog, epilog and invalid bodies
- Parameters:
-
| buf | Pointer to buffer of data |
| len | Length of data in buffer |
The documentation for this class was generated from the following file: