Cleanup of server-constructors. Previous constructors have been marked as deprecated.

This commit is contained in:
eidheim 2016-12-29 09:53:58 +01:00
commit 6c3a59d9ba
6 changed files with 58 additions and 30 deletions

View file

@ -30,7 +30,8 @@ int main() {
//HTTP-server at port 8080 using 1 thread
//Unless you do more heavy non-threaded processing in the resources,
//1 thread is usually faster than several threads
HttpServer server(8080, 1);
HttpServer server;
server.config.port=8080;
//Add resources using path-regex and method-string, and an anonymous function
//POST-example for the path /string, responds the posted string