Represents a connection from a POP client. More...
#include <gpopserver.h>
Public Member Functions | |
ServerPeer (GNet::Server::PeerInfo, Server &, Store &, const Secrets &, std::auto_ptr< ServerProtocol::Text > ptext, ServerProtocol::Config) | |
Constructor. More... | |
virtual bool | protocolSend (const std::string &line, size_t) |
Final override from GPop::ServerProtocol::Sender. More... | |
Public Member Functions inherited from GNet::BufferedServerPeer | |
BufferedServerPeer (Server::PeerInfo, const std::string &eol) | |
Constructor. More... | |
virtual | ~BufferedServerPeer () |
Destructor. More... | |
Public Member Functions inherited from GNet::ServerPeer | |
ServerPeer (Server::PeerInfo) | |
Constructor. More... | |
bool | send (const std::string &data, std::string::size_type offset=0U) |
Sends data down the socket to the peer. More... | |
void | doDelete (const std::string &=std::string()) |
Does "onDelete(); delete this". More... | |
std::string | logId () const |
Returns an identification string for logging purposes. More... | |
virtual std::pair< bool, Address > | localAddress () const |
Returns the local address. More... | |
virtual std::pair< bool, Address > | peerAddress () const |
Returns the peer address. More... | |
virtual std::string | peerCertificate () const |
Returns the peer's TLS certificate. More... | |
virtual void | readEvent () |
Final override from GNet::EventHandler. More... | |
virtual void | writeEvent () |
Final override from GNet::EventHandler. More... | |
virtual void | onException (std::exception &) |
Final override from GNet::EventHandler. More... | |
void | doDeleteThis (int) |
Does delete this. Should only be used by the GNet::Server class. More... | |
Public Member Functions inherited from GNet::EventHandler | |
virtual | ~EventHandler () |
Destructor. More... | |
virtual void | exceptionEvent () |
Called for an exception event. More... | |
Public Member Functions inherited from GNet::Connection | |
virtual | ~Connection () |
Destructor. More... | |
Public Member Functions inherited from GNet::SocketProtocolSink | |
virtual | ~SocketProtocolSink () |
Destructor. More... | |
Protected Member Functions | |
virtual void | onDelete (const std::string &) |
Final override from GNet::ServerPeer. More... | |
virtual bool | onReceive (const std::string &) |
Final override from GNet::BufferedServerPeer. More... | |
virtual void | onSecure (const std::string &) |
Final override from GNet::SocketProtocolSink. More... | |
virtual void | onSendComplete () |
Final override from GNet::BufferedServerPeer. More... | |
virtual bool | securityEnabled () const |
Final override from GPop::ServerProtocol::Security. More... | |
virtual void | securityStart () |
Final override from GPop::ServerProtocol::Security. More... | |
Protected Member Functions inherited from GNet::BufferedServerPeer | |
virtual void | onData (const char *, ServerPeer::size_type) |
Final override from GNet::SocketProtocolSink. More... | |
Protected Member Functions inherited from GNet::ServerPeer | |
virtual | ~ServerPeer () |
Destructor. More... | |
void | sslAccept () |
Waits for the peer to start a secure session. More... | |
StreamSocket & | socket () |
Returns a reference to the client-server connection socket. More... | |
Server * | server () |
Returns a pointer to the associated server object. More... | |
Additional Inherited Members | |
Public Types inherited from GNet::ServerPeer | |
typedef std::string::size_type | size_type |
Represents a connection from a POP client.
Instances are created on the heap by Server (only).
Definition at line 50 of file gpopserver.h.
GPop::ServerPeer::ServerPeer | ( | GNet::Server::PeerInfo | peer_info, |
Server & | server, | ||
Store & | store, | ||
const Secrets & | secrets, | ||
std::auto_ptr< ServerProtocol::Text > | ptext, | ||
ServerProtocol::Config | protocol_config | ||
) |
Constructor.
Definition at line 32 of file gpopserver.cpp.
References GNet::Address::displayString(), G_LOG_S, GPop::ServerProtocol::init(), and GNet::Server::PeerInfo::m_address.
|
protectedvirtual |
Final override from GNet::ServerPeer.
Implements GNet::ServerPeer.
Definition at line 50 of file gpopserver.cpp.
References G_LOG_S.
|
protectedvirtual |
Final override from GNet::BufferedServerPeer.
Implements GNet::BufferedServerPeer.
Definition at line 56 of file gpopserver.cpp.
|
protectedvirtual |
Final override from GNet::SocketProtocolSink.
Implements GNet::SocketProtocolSink.
Definition at line 90 of file gpopserver.cpp.
|
protectedvirtual |
Final override from GNet::BufferedServerPeer.
Implements GNet::ServerPeer.
Definition at line 72 of file gpopserver.cpp.
|
virtual |
Final override from GPop::ServerProtocol::Sender.
Implements GPop::ServerProtocol::Sender.
Definition at line 67 of file gpopserver.cpp.
|
protectedvirtual |
Final override from GPop::ServerProtocol::Security.
Implements GPop::ServerProtocol::Security.
Definition at line 77 of file gpopserver.cpp.
References GSsl::Library::enabled(), G_DEBUG, and GSsl::Library::instance().
|
protectedvirtual |
Final override from GPop::ServerProtocol::Security.
Implements GPop::ServerProtocol::Security.
Definition at line 85 of file gpopserver.cpp.