EHS Embedded HTTP Server
1.5.0.132
|
EHSServer contains all the network related services for EHS. More...
#include <ehsserver.h>
Public Types | |
enum | ServerRunningStatus { SERVERRUNNING_INVALID = 0, SERVERRUNNING_NOTRUNNING, SERVERRUNNING_SINGLETHREADED, SERVERRUNNING_THREADPOOL, SERVERRUNNING_ONETHREADPERREQUEST, SERVERRUNNING_SHOULDTERMINATE } |
Enumeration on the current running status of the EHSServer. | |
Public Member Functions | |
EHSServer (EHS *ipoTopLevelEHS) | |
Constucts a new instance. | |
virtual | ~EHSServer () |
Destructor. | |
void | EndServerThread () |
Stops the server. | |
void | HandleData (int timeout, ehs_threadid_t tid=0) |
Main method that deals with client connections and getting data. | |
ServerRunningStatus | RunningStatus () const |
Retrieves the current running status of this instance. | |
bool | AcceptedNewConnection () const |
Retrieve accept status. | |
int | RequestsPending () const |
Returns number of requests pending. | |
Static Public Member Functions | |
static void * | PthreadHandleData_ThreadedStub (void *ipData) |
Static pthread worker. | |
Friends | |
class | EHSConnection |
EHSServer contains all the network related services for EHS.
It is responsible for accepting new connections and getting EHSConnection objects set up.
Constucts a new instance.
Takes parameters out of the parent's EHSServerParameters.
ipoTopLevelEHS | The parent EHS instance. |
bool AcceptedNewConnection | ( | ) | const [inline] |
Retrieve accept status.
Definition at line 87 of file ehsserver.h.
void EndServerThread | ( | ) |
Stops the server.
This method blocks, until all server threads have terminated.
void HandleData | ( | int | timeout, |
ehs_threadid_t | tid = 0 |
||
) |
Main method that deals with client connections and getting data.
timeout | select timeout in milliseconds. |
tid | Thread Id of the thread calling this method. |
static void* PthreadHandleData_ThreadedStub | ( | void * | ipData | ) | [static] |
Static pthread worker.
Required by pthread as thread routine.
ipData | Opaque pointer to this instance. |
ServerRunningStatus RunningStatus | ( | ) | const [inline] |
Retrieves the current running status of this instance.
Definition at line 81 of file ehsserver.h.