mail::ACCOUNT::getMessageContentDecoded
Prev | mail::ACCOUNT Synchronous API reference | Next

## Name

mail::ACCOUNT::getMessageContentDecoded — Read message content

## Synopsis

#include <libmail/sync.H>
class myStoreCallback : public mail::ACCOUNT::Store {
public:
void search(size_t messageNumber, std::string messageContents);
};
myStoreCallback storeCallback;

mail::ACCOUNT *mail;

`bool ok=mail->getMessageContentDecoded(` | size_t | messageNum,
| bool | peek,
| const mail::mimestruct & | messagePart,
|  | storeCallback`)`;

std::string errmsg=mail->getErrmsg();

## USAGE

`mail::ACCOUNT::getMessagesContentDecoded` is similar to mail::ACCOUNT::getMessageContent(3x) with one key difference: `quoted-printable` and `base64` MIME content is automatically decoded. `storeCallback`'s `store` method receives the decoded binary content.

## Return Codes

This method returns `true` if it succeeds, or `false` if it fails. If the method fails, use `mail::ACCOUNT::getErrmsg()` to read a brief description of the error.

## SEE ALSO

mail::ACCOUNT::getMessageContent(3x), mail::ACCOUNT::getMessageEnvelope(3x), mail::ACCOUNT::getMessageStructure(3x).

Prev | Up | Next
mail::ACCOUNT::getMessageContent | Home | ToC | mail::ACCOUNT::getMessageEnvelope