Fabcoin Core  0.16.2
P2P Digital Currency
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
dev::IpcServerBase< S > Class Template Referenceabstract

#include <IpcServerBase.h>

Inheritance diagram for dev::IpcServerBase< S >:
[legend]
Collaboration diagram for dev::IpcServerBase< S >:
[legend]

Public Member Functions

 IpcServerBase (std::string const &_path)
 
virtual bool StartListening ()
 
virtual bool StopListening ()
 
virtual bool SendResponse (std::string const &_response, void *_addInfo=nullptr)
 

Protected Member Functions

virtual void Listen ()=0
 
virtual void CloseConnection (S _socket)=0
 
virtual size_t Write (S _connection, std::string const &_data)=0
 
virtual size_t Read (S _connection, void *_data, size_t _size)=0
 
void GenerateResponse (S _connection)
 

Protected Attributes

bool m_running = false
 
std::string m_path
 
std::unordered_set< Sm_sockets
 
std::mutex x_sockets
 
std::thread m_listeningThread
 

Detailed Description

template<class S>
class dev::IpcServerBase< S >

Definition at line 33 of file IpcServerBase.h.

Constructor & Destructor Documentation

template<class S>
IpcServerBase::IpcServerBase ( std::string const &  _path)

Definition at line 41 of file IpcServerBase.cpp.

Member Function Documentation

template<class S>
virtual void dev::IpcServerBase< S >::CloseConnection ( S  _socket)
protectedpure virtual

Implemented in dev::UnixDomainSocketServer.

Here is the caller graph for this function:

template<class S>
void IpcServerBase::GenerateResponse ( S  _connection)
protected

Definition at line 97 of file IpcServerBase.cpp.

Here is the call graph for this function:

template<class S>
virtual void dev::IpcServerBase< S >::Listen ( )
protectedpure virtual

Implemented in dev::UnixDomainSocketServer.

Here is the caller graph for this function:

template<class S>
virtual size_t dev::IpcServerBase< S >::Read ( S  _connection,
void *  _data,
size_t  _size 
)
protectedpure virtual

Implemented in dev::UnixDomainSocketServer.

Here is the caller graph for this function:

template<class S>
bool IpcServerBase::SendResponse ( std::string const &  _response,
void *  _addInfo = nullptr 
)
virtual

Definition at line 74 of file IpcServerBase.cpp.

Here is the call graph for this function:

template<class S >
bool IpcServerBase::StartListening ( )
virtual

Reimplemented in dev::UnixDomainSocketServer.

Definition at line 46 of file IpcServerBase.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

template<class S >
bool IpcServerBase::StopListening ( )
virtual

Reimplemented in dev::UnixDomainSocketServer.

Definition at line 57 of file IpcServerBase.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

template<class S>
virtual size_t dev::IpcServerBase< S >::Write ( S  _connection,
std::string const &  _data 
)
protectedpure virtual

Implemented in dev::UnixDomainSocketServer.

Here is the caller graph for this function:

Member Data Documentation

template<class S>
std::thread dev::IpcServerBase< S >::m_listeningThread
protected

Definition at line 53 of file IpcServerBase.h.

template<class S>
std::string dev::IpcServerBase< S >::m_path
protected

Definition at line 50 of file IpcServerBase.h.

template<class S>
bool dev::IpcServerBase< S >::m_running = false
protected

Definition at line 49 of file IpcServerBase.h.

template<class S>
std::unordered_set<S> dev::IpcServerBase< S >::m_sockets
protected

Definition at line 51 of file IpcServerBase.h.

template<class S>
std::mutex dev::IpcServerBase< S >::x_sockets
protected

Definition at line 52 of file IpcServerBase.h.


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