#include "TessesFramework/Http/CallbackServer.hpp" namespace Tesses::Framework::Http { CallbackServer::CallbackServer(std::function cb) : CallbackServer(cb,[]()->void{}) { } CallbackServer::CallbackServer(std::function cb,std::function destroy) { this->cb = cb; this->destroy=destroy; } bool CallbackServer::Handle(ServerContext& ctx) { return this->cb(ctx); } CallbackServer::~CallbackServer() { this->destroy(); } }