zeep::http::server
// In header: </build/libzeep-UaJ1me/libzeep-3.0.5/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 virtual void bind(const std::string &, unsigned short); virtual void run(int); virtual 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 virtual void handle_request(const request &, reply &); virtual 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 virtual void handle_request(boost::asio::ip::tcp::socket &, const request &, reply &); void handle_accept(const boost::system::error_code &); };
server
public member functionsvirtual void bind(const std::string & address, unsigned short port);Bind the server to address and port.
virtual void run(int nr_of_threads);
virtual 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
server
protected member functionsvirtual void handle_request(const request & req, reply & rep);
virtual void log_request(const std::string & client, const request & req, const reply & rep, const boost::posix_time::ptime & start, const std::string & referer, const std::string & userAgent, const std::string & entry);the default entry logger