21 #ifndef G_SMTP_PROTOCOL_MESSAGE_H
22 #define G_SMTP_PROTOCOL_MESSAGE_H
34 class ProtocolMessage ;
77 virtual void reset() = 0 ;
80 virtual void clear() = 0 ;
84 virtual bool setFrom(
const std::string & from_user ,
const std::string & from_auth ) = 0 ;
95 virtual void addReceived(
const std::string & ) = 0 ;
99 virtual bool addText(
const char * ,
size_t ) = 0 ;
109 virtual std::string
from()
const = 0 ;
112 virtual void process(
const std::string & session_auth_id ,
const std::string & peer_socket_address ,
113 const std::string & peer_certificate ) = 0 ;
SMTP and message-store classes.
virtual bool setFrom(const std::string &from_user, const std::string &from_auth)=0
Sets the message envelope 'from'.
virtual void clear()=0
Clears the message state and terminates any asynchronous message processing.
virtual G::Slot::Signal4< bool, unsigned long, std::string, std::string > & doneSignal()=0
Returns a signal which is raised once process() has completed.
virtual void process(const std::string &session_auth_id, const std::string &peer_socket_address, const std::string &peer_certificate)=0
Starts asynchronous processing of the message.
virtual bool addText(const char *, size_t)=0
Adds text.
virtual void addReceived(const std::string &)=0
Adds a 'received' line to the start of the content.
A structure returned by GSmtp::Verifier to describe the status of a 'rcpt-to' recipient.
An interface used by the ServerProtocol class to assemble and process an incoming message...
virtual void reset()=0
Resets the object state as if just constructed.
virtual bool addTo(const std::string &to_user, VerifierStatus to_status)=0
Adds an envelope 'to'.
virtual std::string from() const =0
Returns the setFrom() string.
bool addTextLine(const std::string &)
A convenience function that calls addText() taking a string parameter.
virtual ~ProtocolMessage()
Destructor.