FARGOS/VISTA Object Management Environment Core
..
|
Templatized embedded HTTP server interface; realizes a complete implementation of HTTPembeddedServerBase. More...
#include <HTTPembeddedServer.hpp>
Public Member Functions | |
HTTPembeddedServer (uint16_t port, USER_CLASS *extraData=0, const char *useServerName=0, uint32_t useBfrSize=0, uint16_t maxEventLen=0) | |
virtual | ~HTTPembeddedServer () |
virtual HTTP_SessionRecord * | acceptNewConnection (IO_Processor *io, CircularBufferManager *mgr, const GenericSocketAddress *from, void *extraData) |
USER_CLASS * | getUserData () const |
Returns the user-specific data as a typed value. More... | |
![]() | |
HTTPembeddedServerBase (uint16_t port, void *extraData=nullptr, const char *useServerName=nullptr, uint32_t useBfrSize=0, uint16_t maxEventLength=0) | |
Configures the HTTP server for listening on the indicated port. More... | |
virtual | ~HTTPembeddedServerBase () |
void | setBufferSize (uint32_t bfrSize) |
Alter buffer size used for new accepted client connections. More... | |
void | setHTTPeventLength (uint32_t maxLen) |
Alter maximum length of an HTTP event used for new accepted connections. More... | |
const char * | getServerName () const |
Returns the name associated with the HTTP server. More... | |
int | startHTTPlisten () |
Start the HTTP server. More... | |
int | stopHTTPlisten (const char *reason) |
Stop the HTTP server. More... | |
int | waitForHTTPstop () |
Wait for server to cease operations. More... | |
Additional Inherited Members | |
![]() | |
void * | userData |
OS_SOCKET_TYPE | listenDescriptor |
uint32_t | bufferSize |
uint16_t | maxHTTPeventLength |
uint16_t | listenPort |
bool | stopAccepting |
bool | listenActive |
![]() | |
static int | readHTTPstream (SharedBufferAllocRecord *rec, IO_Processor *controller) |
static void * | startHTTPacceptThread (void *arg) |
![]() | |
char | serverName [64] |
pthread_t | acceptThreadID |
Templatized embedded HTTP server interface; realizes a complete implementation of HTTPembeddedServerBase.
ACCEPT_CLASS must be a subclass of HTTP_SessionRecord USER_CLASS is the type of any optional data to be provided to the new session.
|
inline |
|
inlinevirtual |
|
inlinevirtual |
After the HTTP server has accepted an incoming connection, a new session object is created via a call to acceptNewConnection().
NOTE: this is an abstract function which must be implemented by the subclass realizing the server implementation.
Implements HTTPembeddedServerBase.
References io().
|
inline |
Returns the user-specific data as a typed value.
References HTTPembeddedServerBase::userData.
![]() | Generated: Tue Jul 28 2020 16:03:27
Support Information |