ZNC trunk
Loading...
Searching...
No Matches
CSConnection Class Reference

options for creating a connection More...

#include <Csocket.h>

+ Inheritance diagram for CSConnection:

Public Member Functions

 CSConnection (const CS_STRING &sHostname, uint16_t iPort, int iTimeout=60)
 
virtual ~CSConnection ()
 
const CS_STRINGGetHostname () const
 
const CS_STRINGGetSockName () const
 
const CS_STRINGGetBindHost () const
 
uint16_t GetPort () const
 
int GetTimeout () const
 
bool GetIsSSL () const
 
CSSockAddr::EAFRequire GetAFRequire () const
 
const CS_STRINGGetCipher () const
 
const CS_STRINGGetPemLocation () const
 
const CS_STRINGGetKeyLocation () const
 
const CS_STRINGGetDHParamLocation () const
 
const CS_STRINGGetPemPass () const
 
void SetHostname (const CS_STRING &s)
 sets the hostname to connect to
 
void SetSockName (const CS_STRING &s)
 sets the name of the socket, used for reference, ie in FindSockByName()
 
void SetBindHost (const CS_STRING &s)
 sets the hostname to bind to (vhost support)
 
void SetPort (uint16_t i)
 sets the port to connect to
 
void SetTimeout (int i)
 sets the connection timeout
 
void SetIsSSL (bool b)
 set to true to enable SSL
 
void SetAFRequire (CSSockAddr::EAFRequire iAFRequire)
 sets the AF family type required
 
void SetCipher (const CS_STRING &s)
 set the cipher strength to use, default is HIGH
 
void SetPemLocation (const CS_STRING &s)
 set the location of the pemfile
 
void SetPemPass (const CS_STRING &s)
 set the pemfile pass
 

Protected Attributes

CS_STRING m_sHostname
 
CS_STRING m_sSockName
 
CS_STRING m_sBindHost
 
uint16_t m_iPort
 
int m_iTimeout
 
bool m_bIsSSL
 
CSSockAddr::EAFRequire m_iAFrequire
 
CS_STRING m_sDHParamLocation
 
CS_STRING m_sKeyLocation
 
CS_STRING m_sPemLocation
 
CS_STRING m_sPemPass
 
CS_STRING m_sCipher
 

Detailed Description

options for creating a connection

Constructor & Destructor Documentation

◆ CSConnection()

CSConnection::CSConnection ( const CS_STRING & sHostname,
uint16_t iPort,
int iTimeout = 60 )
inline
Parameters
sHostnamehostname to connect to
iPortport to connect to
iTimeoutconnection timeout

References CS_STRING, m_bIsSSL, m_iAFrequire, m_iPort, m_iTimeout, m_sCipher, m_sHostname, and CSSockAddr::RAF_ANY.

Referenced by CSSSLConnection::CSSSLConnection().

◆ ~CSConnection()

virtual CSConnection::~CSConnection ( )
inlinevirtual

Member Function Documentation

◆ GetAFRequire()

CSSockAddr::EAFRequire CSConnection::GetAFRequire ( ) const
inline

References m_iAFrequire.

◆ GetBindHost()

const CS_STRING & CSConnection::GetBindHost ( ) const
inline

References CS_STRING, and m_sBindHost.

◆ GetCipher()

const CS_STRING & CSConnection::GetCipher ( ) const
inline

References CS_STRING, and m_sCipher.

◆ GetDHParamLocation()

const CS_STRING & CSConnection::GetDHParamLocation ( ) const
inline

References CS_STRING, and m_sDHParamLocation.

◆ GetHostname()

const CS_STRING & CSConnection::GetHostname ( ) const
inline

References CS_STRING, and m_sHostname.

◆ GetIsSSL()

bool CSConnection::GetIsSSL ( ) const
inline

References m_bIsSSL.

◆ GetKeyLocation()

const CS_STRING & CSConnection::GetKeyLocation ( ) const
inline

References CS_STRING, and m_sKeyLocation.

◆ GetPemLocation()

const CS_STRING & CSConnection::GetPemLocation ( ) const
inline

References CS_STRING, and m_sPemLocation.

◆ GetPemPass()

const CS_STRING & CSConnection::GetPemPass ( ) const
inline

References CS_STRING, and m_sPemPass.

◆ GetPort()

uint16_t CSConnection::GetPort ( ) const
inline

References m_iPort.

◆ GetSockName()

const CS_STRING & CSConnection::GetSockName ( ) const
inline

References CS_STRING, and m_sSockName.

◆ GetTimeout()

int CSConnection::GetTimeout ( ) const
inline

References m_iTimeout.

◆ SetAFRequire()

void CSConnection::SetAFRequire ( CSSockAddr::EAFRequire iAFRequire)
inline

sets the AF family type required

References m_iAFrequire.

◆ SetBindHost()

void CSConnection::SetBindHost ( const CS_STRING & s)
inline

sets the hostname to bind to (vhost support)

References CS_STRING, and m_sBindHost.

◆ SetCipher()

void CSConnection::SetCipher ( const CS_STRING & s)
inline

set the cipher strength to use, default is HIGH

References CS_STRING, and m_sCipher.

◆ SetHostname()

void CSConnection::SetHostname ( const CS_STRING & s)
inline

sets the hostname to connect to

References CS_STRING, and m_sHostname.

◆ SetIsSSL()

void CSConnection::SetIsSSL ( bool b)
inline

set to true to enable SSL

References m_bIsSSL.

Referenced by CSSSLConnection::CSSSLConnection().

◆ SetPemLocation()

void CSConnection::SetPemLocation ( const CS_STRING & s)
inline

set the location of the pemfile

References CS_STRING, and m_sPemLocation.

◆ SetPemPass()

void CSConnection::SetPemPass ( const CS_STRING & s)
inline

set the pemfile pass

References CS_STRING, and m_sPemPass.

◆ SetPort()

void CSConnection::SetPort ( uint16_t i)
inline

sets the port to connect to

References m_iPort.

◆ SetSockName()

void CSConnection::SetSockName ( const CS_STRING & s)
inline

sets the name of the socket, used for reference, ie in FindSockByName()

References CS_STRING, and m_sSockName.

◆ SetTimeout()

void CSConnection::SetTimeout ( int i)
inline

sets the connection timeout

References m_iTimeout.

Member Data Documentation

◆ m_bIsSSL

bool CSConnection::m_bIsSSL
protected

Referenced by CSConnection(), GetIsSSL(), and SetIsSSL().

◆ m_iAFrequire

CSSockAddr::EAFRequire CSConnection::m_iAFrequire
protected

◆ m_iPort

uint16_t CSConnection::m_iPort
protected

Referenced by CSConnection(), GetPort(), and SetPort().

◆ m_iTimeout

int CSConnection::m_iTimeout
protected

◆ m_sBindHost

CS_STRING CSConnection::m_sBindHost
protected

Referenced by GetBindHost(), and SetBindHost().

◆ m_sCipher

CS_STRING CSConnection::m_sCipher
protected

Referenced by CSConnection(), GetCipher(), and SetCipher().

◆ m_sDHParamLocation

CS_STRING CSConnection::m_sDHParamLocation
protected

Referenced by GetDHParamLocation().

◆ m_sHostname

CS_STRING CSConnection::m_sHostname
protected

◆ m_sKeyLocation

CS_STRING CSConnection::m_sKeyLocation
protected

Referenced by GetKeyLocation().

◆ m_sPemLocation

CS_STRING CSConnection::m_sPemLocation
protected

Referenced by GetPemLocation(), and SetPemLocation().

◆ m_sPemPass

CS_STRING CSConnection::m_sPemPass
protected

Referenced by GetPemPass(), and SetPemPass().

◆ m_sSockName

CS_STRING CSConnection::m_sSockName
protected

Referenced by GetSockName(), and SetSockName().


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