Skip to content
Snippets Groups Projects
http_route.cpp 410 B
Newer Older
  • Learn to ignore specific revisions
  • Daniel Müller's avatar
    Daniel Müller committed
    #include "http_route.hpp"
    
    HttpRoute::HttpRoute(const std::string &route, HttpHandlerFn handler, 
        HttpRoute::MatchType matchType)
            : route{route}, route_matcher{"^" + route + "$"}, 
                handler_fn {handler}, matchType{matchType}
    { }
    
    const std::string & HttpRoute::getRoute() const
    {
        return route;
    }
    
    const HttpRoute::MatchType & HttpRoute::getMatchType() const
    {
        return matchType;
    }