Kea 2.7.6
http_command_response_creator.h
Go to the documentation of this file.
1// Copyright (C) 2021-2024 Internet Systems Consortium, Inc. ("ISC")
2//
3// This Source Code Form is subject to the terms of the Mozilla Public
4// License, v. 2.0. If a copy of the MPL was not distributed with this
5// file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7#ifndef HTTP_COMMAND_RESPONSE_CREATOR_H
8#define HTTP_COMMAND_RESPONSE_CREATOR_H
9
12#include <boost/shared_ptr.hpp>
13
14namespace isc {
15namespace config {
16
32public:
33
38 }
39
41 virtual ~HttpCommandResponseCreator() = default;
42
51
60 const http::HttpStatusCode& status_code) const;
61
64 return (config_);
65 }
66
67private:
68
80 createStockHttpResponseInternal(const http::HttpRequestPtr& request,
81 const http::HttpStatusCode& status_code) const;
82
88 createDynamicHttpResponse(http::HttpRequestPtr request);
89
94};
95
97typedef boost::shared_ptr<HttpCommandResponseCreator>
99
100} // end of namespace isc::config
101} // end of namespace isc
102
103#endif
Concrete implementation of the HTTP response creator used for HTTP control socket.
HttpCommandConfigPtr getHttpCommandConfig() const
Returns HTTP control socket config.
virtual http::HttpRequestPtr createNewHttpRequest() const
Create a new request.
virtual http::HttpResponsePtr createStockHttpResponse(const http::HttpRequestPtr &request, const http::HttpStatusCode &status_code) const
Creates stock HTTP response.
virtual ~HttpCommandResponseCreator()=default
virtual destructor.
HttpCommandResponseCreator(HttpCommandConfigPtr config)
Constructor.
Specifies an interface for classes creating HTTP responses from HTTP requests.
boost::shared_ptr< HttpCommandResponseCreator > HttpCommandResponseCreatorPtr
Pointer to the HttpCommandResponseCreator.
boost::shared_ptr< HttpCommandConfig > HttpCommandConfigPtr
Pointer to a HttpCommandConfig object.
HttpStatusCode
HTTP status codes (cf RFC 2068)
Definition response.h:30
boost::shared_ptr< HttpResponse > HttpResponsePtr
Pointer to the HttpResponse object.
Definition response.h:81
boost::shared_ptr< HttpRequest > HttpRequestPtr
Pointer to the HttpRequest object.
Definition request.h:30
Defines the logger used by the top-level component of kea-lfc.