zeep::http::server
// In header: </home/maarten/projects/libzeep/zeep/http/server.hpp> class server : public zeep::http::request_handler { public: // construct/copy/destruct server(); server(const server &); server& operator=(const server &); ~server(); // public member functions void bind(const std::string &, unsigned short); void run(int); void stop(); void log_forwarded(bool); std::string address() const; unsigned short port() const; boost::asio::io_service & get_io_service(); // public static functions static std::ostream & log(); // protected member functions void handle_request(const request &, reply &); void log_request(const std::string &, const request &, const reply &, const boost::posix_time::ptime &, const std::string &, const std::string &, const std::string &); // private member functions void handle_request(boost::asio::ip::tcp::socket &, const request &, reply &); void handle_accept(const boost::system::error_code &); };
server
public member functionsvoid bind(const std::string & address, unsigned short port);Bind the server to address and port.
void run(int nr_of_threads);
void stop();
void log_forwarded(bool v);log_forwarded tells the HTTP server to use the last entry in X-Forwarded-For as client log entry
std::string address() const;
unsigned short port() const;
boost::asio::io_service & get_io_service();get_io_service has to be public since we need it to call notify_fork from child code