E-MailRelay
|
A structure containing the contents of an envelope file, with support for file reading, writing and copying. More...
#include <genvelope.h>
Static Public Member Functions | |
static void | read (std::istream &, Envelope &) |
Reads an envelope from a stream. More... | |
static std::size_t | write (std::ostream &, const Envelope &) |
Writes an envelope to a seekable stream. More... | |
static void | copyExtra (std::istream &, std::ostream &) |
A convenience function to copy extra envelope lines from an envelope input stream to an output stream. More... | |
static MessageStore::BodyType | parseSmtpBodyType (const std::string &, MessageStore::BodyType default_=MessageStore::BodyType::Unknown) |
Parses an SMTP MAIL-FROM BODY= parameter. More... | |
static std::string | smtpBodyType (MessageStore::BodyType) |
Converts a body type enum into the corresponding SMTP keyword. More... | |
Public Attributes | |
bool | crlf {true} |
bool | utf8_mailboxes {false} |
MessageStore::BodyType | body_type {MessageStore::BodyType::Unknown} |
std::string | from |
G::StringArray | to_local |
G::StringArray | to_remote |
std::string | authentication |
std::string | client_socket_address |
std::string | client_certificate |
std::string | from_auth_in |
std::string | from_auth_out |
std::string | forward_to |
std::string | forward_to_address |
std::string | client_account_selector |
std::size_t | endpos {0U} |
A structure containing the contents of an envelope file, with support for file reading, writing and copying.
Definition at line 40 of file genvelope.h.
|
static |
A convenience function to copy extra envelope lines from an envelope input stream to an output stream.
Input lines can be newline delimited, but output is always CR-LF. Throws on input error; output errors are not checked.
Definition at line 99 of file genvelope.cpp.
|
static |
Parses an SMTP MAIL-FROM BODY= parameter.
Returns the given default value if the string is empty.
Definition at line 175 of file genvelope.cpp.
|
static |
Reads an envelope from a stream.
Throws on error. Input lines can be newline delimited, in which case 'crlf' is set false.
Definition at line 113 of file genvelope.cpp.
|
static |
Converts a body type enum into the corresponding SMTP keyword.
Definition at line 182 of file genvelope.cpp.
|
static |
Writes an envelope to a seekable stream.
Returns the new endpos value. Returns zero and sets the fail state on error, if for example the stream is unseekable. Output lines are CR-LF delimited. The structure 'crlf' and 'endpos' fields should normally be updated after using write().
Definition at line 59 of file genvelope.cpp.
std::string GStore::Envelope::authentication |
Definition at line 81 of file genvelope.h.
MessageStore::BodyType GStore::Envelope::body_type {MessageStore::BodyType::Unknown} |
Definition at line 77 of file genvelope.h.
std::string GStore::Envelope::client_account_selector |
Definition at line 88 of file genvelope.h.
std::string GStore::Envelope::client_certificate |
Definition at line 83 of file genvelope.h.
std::string GStore::Envelope::client_socket_address |
Definition at line 82 of file genvelope.h.
bool GStore::Envelope::crlf {true} |
Definition at line 75 of file genvelope.h.
std::size_t GStore::Envelope::endpos {0U} |
Definition at line 89 of file genvelope.h.
std::string GStore::Envelope::forward_to |
Definition at line 86 of file genvelope.h.
std::string GStore::Envelope::forward_to_address |
Definition at line 87 of file genvelope.h.
std::string GStore::Envelope::from |
Definition at line 78 of file genvelope.h.
std::string GStore::Envelope::from_auth_in |
Definition at line 84 of file genvelope.h.
std::string GStore::Envelope::from_auth_out |
Definition at line 85 of file genvelope.h.
G::StringArray GStore::Envelope::to_local |
Definition at line 79 of file genvelope.h.
G::StringArray GStore::Envelope::to_remote |
Definition at line 80 of file genvelope.h.
bool GStore::Envelope::utf8_mailboxes {false} |
Definition at line 76 of file genvelope.h.