Scheduler< Impl, ImplPtr >::ConnReq Class Reference

#include <scheduler.h>

Inheritance diagram for Scheduler< Impl, ImplPtr >::ConnReq:

Inheritance graph
[legend]
Collaboration diagram for Scheduler< Impl, ImplPtr >::ConnReq:

Collaboration graph
[legend]
List of all members.

Detailed Description

template<typename Impl, typename ImplPtr = Impl*>
class Scheduler< Impl, ImplPtr >::ConnReq

Connection request indicates we wish to perform an outgoing connection.

When we are allowed to perform the actual connecting, SchedBase calls our doConn() member, where we may perform the actual connecting.

Definition at line 761 of file scheduler.h.


Public Member Functions

 ConnReq (const SSocketWrapper &s, IPV4Address addr, uint32_t timeout)
 Construct.
 ~ConnReq ()
 Destroy.
virtual int doConn ()
 Initialize the actual connection.
virtual void notify () const
 Notify client code; only SOCK_CONNFAILED is emitted here, because SOCK_CONNECTED is received via events from underlying socket API.

Private Member Functions

 ConnReq ()
 Forbidden.

Private Attributes

SSocketWrapper m_obj
 Socket reference data.
IPV4Address m_addr
 Address to connect to.
uint32_t m_timeout
 Optional connect timeout.

Constructor & Destructor Documentation

template<typename Impl, typename ImplPtr = Impl*>
Scheduler< Impl, ImplPtr >::ConnReq::ConnReq const SSocketWrapper s,
IPV4Address  addr,
uint32_t  timeout
[inline]
 

Construct.

Definition at line 764 of file scheduler.h.

References CHECK_FAIL, Scheduler< Impl, ImplPtr >::ConnReq::m_addr, Scheduler< Impl, ImplPtr >::ConnReq::m_obj, Scheduler< Impl, ImplPtr >::ConnReq::m_timeout, and Scheduler< Impl, ImplPtr >::s_connReqs.

template<typename Impl, typename ImplPtr = Impl*>
Scheduler< Impl, ImplPtr >::ConnReq::~ConnReq  )  [inline]
 

Destroy.

Definition at line 777 of file scheduler.h.

References Scheduler< Impl, ImplPtr >::SSocketWrapper::getSocket(), Scheduler< Impl, ImplPtr >::ConnReq::m_obj, and Scheduler< Impl, ImplPtr >::s_connReqs.

Here is the call graph for this function:

template<typename Impl, typename ImplPtr = Impl*>
Scheduler< Impl, ImplPtr >::ConnReq::ConnReq  )  [private]
 

Forbidden.


Member Function Documentation

template<typename Impl, typename ImplPtr = Impl*>
virtual int Scheduler< Impl, ImplPtr >::ConnReq::doConn  )  [inline, virtual]
 

Initialize the actual connection.

Returns:
If the attempt succeeded or not

Implements SchedBase::ConnReqBase.

Definition at line 786 of file scheduler.h.

References Scheduler< Impl, ImplPtr >::SSocketWrapper::getSocket(), Scheduler< Impl, ImplPtr >::ConnReq::m_addr, Scheduler< Impl, ImplPtr >::ConnReq::m_obj, and Scheduler< Impl, ImplPtr >::ConnReq::m_timeout.

Here is the call graph for this function:

template<typename Impl, typename ImplPtr = Impl*>
virtual void Scheduler< Impl, ImplPtr >::ConnReq::notify  )  const [inline, virtual]
 

Notify client code; only SOCK_CONNFAILED is emitted here, because SOCK_CONNECTED is received via events from underlying socket API.

Implements SchedBase::ReqBase.

Definition at line 798 of file scheduler.h.

References Scheduler< Impl, ImplPtr >::ConnReq::m_obj, Scheduler< Impl, ImplPtr >::SSocketWrapper::notify(), and SOCK_CONNFAILED.

Here is the call graph for this function:


Member Data Documentation

template<typename Impl, typename ImplPtr = Impl*>
IPV4Address Scheduler< Impl, ImplPtr >::ConnReq::m_addr [private]
 

Address to connect to.

Definition at line 804 of file scheduler.h.

Referenced by Scheduler< Impl, ImplPtr >::ConnReq::ConnReq(), and Scheduler< Impl, ImplPtr >::ConnReq::doConn().

template<typename Impl, typename ImplPtr = Impl*>
SSocketWrapper Scheduler< Impl, ImplPtr >::ConnReq::m_obj [private]
 

Socket reference data.

Definition at line 803 of file scheduler.h.

Referenced by Scheduler< Impl, ImplPtr >::ConnReq::ConnReq(), Scheduler< Impl, ImplPtr >::ConnReq::doConn(), Scheduler< Impl, ImplPtr >::ConnReq::notify(), and Scheduler< Impl, ImplPtr >::ConnReq::~ConnReq().

template<typename Impl, typename ImplPtr = Impl*>
uint32_t Scheduler< Impl, ImplPtr >::ConnReq::m_timeout [private]
 

Optional connect timeout.

Definition at line 805 of file scheduler.h.

Referenced by Scheduler< Impl, ImplPtr >::ConnReq::ConnReq(), and Scheduler< Impl, ImplPtr >::ConnReq::doConn().


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