MongoDB  2.6.0
Public Member Functions | Public Attributes | List of all members
mongo::SockAddr Struct Reference

wrapped around os representation of network address More...

#include <sock.h>

Public Member Functions

 SockAddr (int sourcePort)
 
 SockAddr (const char *ip, int port)
 
template<typename T >
T & as ()
 
template<typename T >
const T & as () const
 
std::string toString (bool includePort=true) const
 
sa_family_t getType () const
 
unsigned getPort () const
 
std::string getAddr () const
 
bool isLocalHost () const
 
bool operator== (const SockAddr &r) const
 
bool operator!= (const SockAddr &r) const
 
bool operator< (const SockAddr &r) const
 
const sockaddr * raw () const
 
sockaddr * raw ()
 

Public Attributes

socklen_t addressSize
 

Detailed Description

wrapped around os representation of network address

Member Function Documentation

sa_family_t mongo::SockAddr::getType ( ) const
Returns
one of AF_INET, AF_INET6, or AF_UNIX

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