/* * Copyright 2015 Cloudius Systems */ #ifndef API_API_HH_ #define API_API_HH_ #include "http/httpd.hh" #include "database.hh" #include namespace api { struct http_context { http_server_control http_server; distributed& db; http_context(distributed& _db) : db(_db) {} }; future<> set_server(http_context& ctx); template std::vector container_to_vec(const T& container) { std::vector res; for (auto i : container) { res.push_back(boost::lexical_cast(i)); } return res; } } #endif /* API_API_HH_ */