MongoDB  2.7.0
Public Member Functions | Static Public Member Functions | Public Attributes | Friends | List of all members
mongo::MessagingPort Class Reference
Inheritance diagram for mongo::MessagingPort:
mongo::AbstractMessagingPort

Public Member Functions

 MessagingPort (int fd, const SockAddr &remote)
 
 MessagingPort (double so_timeout=0, logger::LogSeverity logLevel=logger::LogSeverity::Log())
 
 MessagingPort (boost::shared_ptr< Socket > socket)
 
void setSocketTimeout (double timeout)
 
void shutdown ()
 
bool recv (Message &m)
 
void reply (Message &received, Message &response, MSGID responseTo)
 
void reply (Message &received, Message &response)
 
bool call (Message &toSend, Message &response)
 
void say (Message &toSend, int responseTo=0)
 
bool recv (const Message &sent, Message &response)
 this is used for doing 'async' queries instead of doing call( to , from ) you would do say( to ) recv( from ) Note: if you fail to call recv and someone else uses this port, horrible things will happen
 
void piggyBack (Message &toSend, int responseTo=0)
 
unsigned remotePort () const
 
virtual HostAndPort remote () const
 
virtual SockAddr remoteAddr () const
 
virtual SockAddr localAddr () const
 
void send (const char *data, int len, const char *context)
 
void send (const std::vector< std::pair< char *, int > > &data, const char *context)
 
bool connect (SockAddr &farEnd)
 
bool isStillConnected ()
 
uint64_t getSockCreationMicroSec () const
 
- Public Member Functions inherited from mongo::AbstractMessagingPort
void setX509SubjectName (const std::string &x509SubjectName)
 
std::string getX509SubjectName ()
 
long long connectionId () const
 
void setConnectionId (long long connectionId)
 

Static Public Member Functions

static void closeAllSockets (unsigned tagMask=0xffffffff)
 

Public Attributes

boost::shared_ptr< Socketpsock
 
- Public Attributes inherited from mongo::AbstractMessagingPort
unsigned tag
 

Friends

class PiggyBackData
 

The documentation for this class was generated from the following files: