#include <SocketBaseImpl.hpp>
Inheritance diagram for BLOCXX_NAMESPACE::SocketBaseImpl:
Public Member Functions | |
SocketBaseImpl () | |
SocketBaseImpl (SocketHandle_t fd, SocketAddress::AddressType addrType) | |
SocketBaseImpl (const SocketAddress &addr) | |
virtual | ~SocketBaseImpl () |
virtual void | connect (const SocketAddress &addr) |
virtual void | disconnect () |
void | setReceiveTimeout (int seconds) |
int | getReceiveTimeout () const |
void | setSendTimeout (int seconds) |
int | getSendTimeout () const |
void | setConnectTimeout (int seconds) |
int | getConnectTimeout () const |
void | setTimeouts (int seconds) |
bool | receiveTimeOutExpired () const |
int | write (const void *dataOut, int dataOutLen, bool errorAsException=false) |
Write a specified number of bytes to the device that is exposing the IOIFC interface. | |
int | read (void *dataIn, int dataInLen, bool errorAsException=false) |
Read a specified number of bytes from the device that is exposing the IOIFC interface. | |
virtual bool | waitForInput (int timeOutSecs=-1) |
bool | waitForOutput (int timeOutSecs=-1) |
std::istream & | getInputStream () |
std::ostream & | getOutputStream () |
std::iostream & | getIOStream () |
SocketAddress | getLocalAddress () const |
SocketAddress | getPeerAddress () const |
SocketHandle_t | getfd () const |
Select_t | getSelectObj () const |
bool | isConnected () const |
Static Public Member Functions | |
static void | setDumpFiles (const String &in, const String &out) |
Protected Member Functions | |
virtual int | readAux (void *dataIn, int dataInLen)=0 |
virtual int | writeAux (const void *dataOut, int dataOutLen)=0 |
Protected Attributes | |
bool | m_isConnected |
SocketHandle_t | m_sockfd |
SocketAddress | m_localAddress |
SocketAddress | m_peerAddress |
Private Member Functions | |
void | fillInetAddrParms () |
void | fillUnixAddrParms () |
SocketBaseImpl (const SocketBaseImpl &arg) | |
SocketBaseImpl & | operator= (const SocketBaseImpl &arg) |
Private Attributes | |
bool | m_recvTimeoutExprd |
SocketStreamBuffer | m_streamBuf |
std::istream | m_in |
std::ostream | m_out |
std::iostream | m_inout |
int | m_recvTimeout |
int | m_sendTimeout |
int | m_connectTimeout |
Static Private Attributes | |
static String | m_traceFileOut |
static String | m_traceFileIn |
Definition at line 65 of file SocketBaseImpl.hpp.
|
Definition at line 92 of file SocketBaseImpl.cpp. |
|
Definition at line 112 of file SocketBaseImpl.cpp. References BLOCXX_ASSERT, fillInetAddrParms(), fillUnixAddrParms(), BLOCXX_NAMESPACE::SocketAddress::INET, m_inout, m_out, and BLOCXX_NAMESPACE::SocketAddress::UDS. |
|
Definition at line 145 of file SocketBaseImpl.cpp. References connect(), m_inout, m_out, and m_peerAddress. |
|
Definition at line 166 of file SocketBaseImpl.cpp. References disconnect(). |
|
|
|
Definition at line 185 of file SocketBaseImpl.cpp. References BLOCXX_ASSERT, BLOCXX_THROW_ERRNO_MSG, disconnect(), BLOCXX_NAMESPACE::SocketAddress::getType(), BLOCXX_NAMESPACE::SocketAddress::INET, m_in, m_inout, m_isConnected, m_out, m_sockfd, m_streamBuf, BLOCXX_NAMESPACE::IOIFCStreamBuffer::reset(), and BLOCXX_NAMESPACE::SocketAddress::UDS. Referenced by SocketBaseImpl(). |
|
Definition at line 361 of file SocketBaseImpl.cpp. References BLOCXX_NAMESPACE::FileSystem::close(), m_in, m_inout, m_isConnected, and m_out. Referenced by connect(), and ~SocketBaseImpl(). |
|
Definition at line 385 of file SocketBaseImpl.cpp. References BLOCXX_NAMESPACE::SocketAddress::assignFromNativeForm(), m_localAddress, and m_peerAddress. Referenced by SocketBaseImpl(). |
|
Definition at line 415 of file SocketBaseImpl.cpp. References BLOCXX_NAMESPACE::SocketAddress::assignFromNativeForm(), BLOCXX_THROW_ERRNO_MSG, m_localAddress, and m_peerAddress. Referenced by SocketBaseImpl(). |
|
Definition at line 79 of file SocketBaseImpl.hpp. |
|
Definition at line 93 of file SocketBaseImpl.hpp. |
|
Definition at line 565 of file SocketBaseImpl.cpp. References m_in. |
|
Definition at line 577 of file SocketBaseImpl.cpp. References m_inout. |
|
Definition at line 91 of file SocketBaseImpl.hpp. |
|
Definition at line 571 of file SocketBaseImpl.cpp. References m_out. |
|
Definition at line 92 of file SocketBaseImpl.hpp. |
|
Definition at line 75 of file SocketBaseImpl.hpp. |
|
Implements BLOCXX_NAMESPACE::SelectableIFC. Reimplemented in BLOCXX_NAMESPACE::SocketImpl. Definition at line 179 of file SocketBaseImpl.cpp. References m_sockfd. |
|
Definition at line 77 of file SocketBaseImpl.hpp. |
|
Definition at line 95 of file SocketBaseImpl.hpp. |
|
|
|
Read a specified number of bytes from the device that is exposing the IOIFC interface.
Implements BLOCXX_NAMESPACE::IOIFC. Definition at line 486 of file SocketBaseImpl.cpp. References BLOCXX_THROW_ERRNO_MSG, BLOCXX_NAMESPACE::String::c_str(), BLOCXX_NAMESPACE::String::empty(), BLOCXX_NAMESPACE::DateTime::getMicrosecond(), BLOCXX_NAMESPACE::guard, m_isConnected, m_recvTimeout, m_traceFileIn, m_traceFileOut, readAux(), BLOCXX_NAMESPACE::DateTime::setToCurrent(), BLOCXX_NAMESPACE::DateTime::toString(), and waitForInput(). |
|
Implemented in BLOCXX_NAMESPACE::SocketImpl. Referenced by read(). |
|
Definition at line 81 of file SocketBaseImpl.hpp. |
|
Definition at line 78 of file SocketBaseImpl.hpp. |
|
Definition at line 584 of file SocketBaseImpl.cpp. References m_traceFileIn, and m_traceFileOut. |
|
Definition at line 74 of file SocketBaseImpl.hpp. |
|
Definition at line 76 of file SocketBaseImpl.hpp. |
|
Definition at line 80 of file SocketBaseImpl.hpp. |
|
Definition at line 544 of file SocketBaseImpl.cpp. References BLOCXX_NAMESPACE::SocketFlags::E_WAIT_FOR_INPUT, ETIMEDOUT, m_recvTimeoutExprd, and BLOCXX_NAMESPACE::SocketUtils::waitForIO(). Referenced by read(). |
|
Definition at line 559 of file SocketBaseImpl.cpp. References BLOCXX_NAMESPACE::SocketFlags::E_WAIT_FOR_OUTPUT, and BLOCXX_NAMESPACE::SocketUtils::waitForIO(). Referenced by write(). |
|
Write a specified number of bytes to the device that is exposing the IOIFC interface.
Implements BLOCXX_NAMESPACE::IOIFC. Definition at line 431 of file SocketBaseImpl.cpp. References BLOCXX_THROW_ERRNO_MSG, BLOCXX_NAMESPACE::String::c_str(), BLOCXX_NAMESPACE::String::empty(), BLOCXX_NAMESPACE::DateTime::getMicrosecond(), BLOCXX_NAMESPACE::guard, m_isConnected, m_sendTimeout, m_traceFileOut, BLOCXX_NAMESPACE::DateTime::setToCurrent(), BLOCXX_NAMESPACE::DateTime::toString(), waitForOutput(), and writeAux(). |
|
Implemented in BLOCXX_NAMESPACE::SocketImpl. Referenced by write(). |
|
Definition at line 127 of file SocketBaseImpl.hpp. |
|
Definition at line 122 of file SocketBaseImpl.hpp. Referenced by connect(), disconnect(), and getInputStream(). |
|
Definition at line 124 of file SocketBaseImpl.hpp. Referenced by connect(), disconnect(), getIOStream(), and SocketBaseImpl(). |
|
Definition at line 101 of file SocketBaseImpl.hpp. Referenced by connect(), disconnect(), read(), and write(). |
|
Definition at line 103 of file SocketBaseImpl.hpp. Referenced by fillInetAddrParms(), and fillUnixAddrParms(). |
|
Definition at line 123 of file SocketBaseImpl.hpp. Referenced by connect(), disconnect(), getOutputStream(), and SocketBaseImpl(). |
|
Definition at line 104 of file SocketBaseImpl.hpp. Referenced by fillInetAddrParms(), fillUnixAddrParms(), and SocketBaseImpl(). |
|
Definition at line 125 of file SocketBaseImpl.hpp. Referenced by read(). |
|
Definition at line 120 of file SocketBaseImpl.hpp. Referenced by waitForInput(). |
|
Definition at line 126 of file SocketBaseImpl.hpp. Referenced by write(). |
|
Definition at line 102 of file SocketBaseImpl.hpp. Referenced by connect(), BLOCXX_NAMESPACE::SocketImpl::getSelectObj(), getSelectObj(), BLOCXX_NAMESPACE::SocketImpl::readAux(), and BLOCXX_NAMESPACE::SocketImpl::writeAux(). |
|
Definition at line 121 of file SocketBaseImpl.hpp. Referenced by connect(). |
|
Definition at line 130 of file SocketBaseImpl.hpp. Referenced by read(), and setDumpFiles(). |
|
Definition at line 129 of file SocketBaseImpl.hpp. Referenced by read(), setDumpFiles(), and write(). |