The C++ framework for developing highly scalable, high performance servers on Windows platforms.

CFullAddress Class Reference
[Addresses]

Inheritance diagram for CFullAddress:
Collaboration diagram for CFullAddress:

List of all members.


Detailed Description

A class that uses hard coded assumptions to fabricate "full addresses" from a SOCADDR structure and and is somewhat fragile in the face of new address family support. Essentially we guess the protocol, which isn't that hard.


Public Member Functions

 CFullAddress (const IAddress &address)
 Creates a CFullAddress object that represents the supplied address.
 CFullAddress (const sockaddr &address, int size)
 Creates a CFullAddress object that represents the supplied address.
 CFullAddress (const JetByteTools::Core::_tstring &hexOrDottedIPorName, IIPAddress::Port port)
 Creates a CFullAddress object for an IP address from the supplied address in IPv4 dotted IP format "xxx.xxx.xxx.xxx" or IPv6 hex IP format: "ffff:ffff:ffff:ffff:ffff" or from a host name, and a port.
 CFullAddress (const JetByteTools::Core::_tstring &hexOrDottedIPorName, IIPAddress::Port port, const IAddressType &addressTypePreference)
 Creates a CFullAddress object for an IP address from the supplied address in IPv4 dotted IP format "xxx.xxx.xxx.xxx" or IPv6 hex IP format: "ffff:ffff:ffff:ffff:ffff" or from a host name, and a port. Where a host name is supplied the address selection preference can be specified if it's important to you.
 CFullAddress (const JetByteTools::Core::_tstring &addressAsString)
 Creates a CFullAddress object for an IP address from the supplied address either IPv4 format: "xxx.xxx.xxx.xxx:port" or in IPv6 format: "[ffff:ffff:ffff:ffff:ffff]:port".
 CFullAddress (const CFullAddress &rhs)
 CFullAddress (const CAddress &rhs)
CFullAddressoperator= (const CFullAddress &rhs)
CFullAddressoperator= (const CAddress &rhs)
const IAddressTypeType () const override
 Returns the address type for the address.
IFullAddressClone () const override
 Dynamically allocates a copy of this address. You are responsible for deallocating this copy with delete when you're done with it..
bool IsWildcardAddress () const override
unsigned short Family () const override
 Returns the address family of the address.
const sockaddr & AsSockAddr () const override
 Returns the address as a reference to a sockaddr structure.
int Size () const override
 Returns the size of the sockaddr structure required to store the address.
IAddressRefGetAddressRef () const override
 Returns a reference counted view on this address, be sure to call Release() on the IAdressRef when you're done with it.

Static Public Member Functions

static bool IsValid (const IAddress &address)
static bool IsSameAddress (const IAddress &lhs, const IAddress &rhs)


Constructor & Destructor Documentation

CFullAddress ( const IAddress address  )  [explicit]

Creates a CFullAddress object that represents the supplied address.

CFullAddress ( const sockaddr &  address,
int  size 
)

Creates a CFullAddress object that represents the supplied address.

CFullAddress ( const JetByteTools::Core::_tstring hexOrDottedIPorName,
IIPAddress::Port  port 
)

Creates a CFullAddress object for an IP address from the supplied address in IPv4 dotted IP format "xxx.xxx.xxx.xxx" or IPv6 hex IP format: "ffff:ffff:ffff:ffff:ffff" or from a host name, and a port.

CFullAddress ( const JetByteTools::Core::_tstring hexOrDottedIPorName,
IIPAddress::Port  port,
const IAddressType addressTypePreference 
)

Creates a CFullAddress object for an IP address from the supplied address in IPv4 dotted IP format "xxx.xxx.xxx.xxx" or IPv6 hex IP format: "ffff:ffff:ffff:ffff:ffff" or from a host name, and a port. Where a host name is supplied the address selection preference can be specified if it's important to you.

CFullAddress ( const JetByteTools::Core::_tstring addressAsString  )  [explicit]

Creates a CFullAddress object for an IP address from the supplied address either IPv4 format: "xxx.xxx.xxx.xxx:port" or in IPv6 format: "[ffff:ffff:ffff:ffff:ffff]:port".

CFullAddress ( const CFullAddress rhs  ) 

CFullAddress ( const CAddress rhs  )  [explicit]


Member Function Documentation

CFullAddress & operator= ( const CFullAddress rhs  ) 

CFullAddress & operator= ( const CAddress rhs  ) 

const IAddressType & Type (  )  const [override, virtual]

Returns the address type for the address.

Implements IFullAddress.

IFullAddress * Clone (  )  const [override, virtual]

Dynamically allocates a copy of this address. You are responsible for deallocating this copy with delete when you're done with it..

Implements IFullAddress.

bool IsWildcardAddress (  )  const [override, virtual]

Implements IFullAddress.

unsigned short Family (  )  const [override, virtual]

Returns the address family of the address.

Implements IAddress.

const sockaddr & AsSockAddr (  )  const [override, virtual]

Returns the address as a reference to a sockaddr structure.

Implements IAddress.

int Size (  )  const [override, virtual]

Returns the size of the sockaddr structure required to store the address.

Implements IAddress.

IAddressRef * GetAddressRef (  )  const [override, virtual]

Returns a reference counted view on this address, be sure to call Release() on the IAdressRef when you're done with it.

Implements IAddress.

bool IsValid ( const IAddress address  )  [static, inherited]

bool IsSameAddress ( const IAddress lhs,
const IAddress rhs 
) [static, inherited]


Generated on Sun Sep 12 19:10:12 2021 for The Server Framework - v7.4 by doxygen 1.5.3