EPICS ARCHIVER V4
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups
Public Member Functions | List of all members
HTTPServer Class Reference

An in-memory web server. More...

#include <HTTPServer.h>

Inheritance diagram for HTTPServer:
EngineServer

Public Member Functions

 HTTPServer (short port, PathHandlerList *handlers, void *user_arg)
 Create a HTTPServer. More...
 
void start ()
 Start accepting connections (launch thread). More...
 
void run ()
 Part of the epicsThreadRunable interface. More...
 
void serverinfo (SOCKET socket)
 Dump HTML page with server info to socket. More...
 
PathHandlerListgetHandlers () const
 
void * getUserArg () const
 
bool isShuttingDown () const
 

Detailed Description

An in-memory web server.

Waits for connections on the given TCP port, creates an HTTPClientConnection for each incoming, well, client.

The HTTPClientConnection then needs to handle the incoming requests and produce appropriate and hopefully strikingly beautiful HTML pages.

Constructor & Destructor Documentation

HTTPServer::HTTPServer ( short  port,
PathHandlerList handlers,
void *  user_arg 
)

Create a HTTPServer.

Parameters
portThe TCP port number where the server listens.
handlershandlers
user_arguser arguments
Exceptions
GenericExceptionwhen port unavailable.
See Also
start()

Member Function Documentation

PathHandlerList* HTTPServer::getHandlers ( ) const
inline
Returns
Returns the path handlers for this HTTPServer.
void* HTTPServer::getUserArg ( ) const
inline
Returns
Returns the user arg passed to the constructor.
bool HTTPServer::isShuttingDown ( ) const
inline
Returns
Returns true if the server wants to shut down.
void HTTPServer::run ( )

Part of the epicsThreadRunable interface.

Do not call directly!

void HTTPServer::serverinfo ( SOCKET  socket)

Dump HTML page with server info to socket.

void HTTPServer::start ( )

Start accepting connections (launch thread).


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