HttpServer Class Reference

Interface to a HttpServer port. More...

#include <Devices/HTTPServer.H>

Inheritance diagram for HttpServer:
Inheritance graph
[legend]
Collaboration diagram for HttpServer:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 HttpServer (OptionManager &mgr, const std::string &descrName="HttpServer Port", const std::string &tagName="HttpServerPort")
 Constructor.
 ~HttpServer (void)
 destructor
int acceptConn ()
 Accept a connection and return the connection fd.
int writeData (int clientFd, std::string &msg)
 write a string to the client fd

Protected Member Functions

void start1 ()
 open the port and get started
void stop2 ()
 close the port and get stopped

Protected Attributes

OModelParam< unsigned int > itsPort
 Resolve hostname to ip address.

Detailed Description

Interface to a HttpServer port.

The socket will be open at start() time; see ModelComponent.H for details.

Definition at line 58 of file HTTPServer.H.


Constructor & Destructor Documentation

HttpServer::HttpServer ( OptionManager mgr,
const std::string descrName = "HttpServer Port",
const std::string tagName = "HttpServerPort" 
)

Constructor.

Definition at line 68 of file HTTPServer.C.

HttpServer::~HttpServer ( void   ) 

destructor

Definition at line 79 of file HTTPServer.C.


Member Function Documentation

int HttpServer::acceptConn (  ) 

Accept a connection and return the connection fd.

Definition at line 129 of file HTTPServer.C.

void HttpServer::start1 (  )  [protected, virtual]

open the port and get started

Reimplemented from ModelComponent.

Definition at line 88 of file HTTPServer.C.

References OModelParam< T >::getVal(), and itsPort.

void HttpServer::stop2 (  )  [protected, virtual]

close the port and get stopped

Reimplemented from ModelComponent.

Definition at line 124 of file HTTPServer.C.

int HttpServer::writeData ( int  clientFd,
std::string msg 
)

write a string to the client fd

Definition at line 137 of file HTTPServer.C.


Member Data Documentation

OModelParam<unsigned int> HttpServer::itsPort [protected]

Resolve hostname to ip address.

The port we listen on

Definition at line 76 of file HTTPServer.H.

Referenced by start1().


The documentation for this class was generated from the following files:
Generated on Sun May 8 08:22:15 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3