Kea  2.1.7-git
ca_response_creator.h
Go to the documentation of this file.
1 // Copyright (C) 2017-2021 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 CTRL_AGENT_RESPONSE_CREATOR_H
8 #define CTRL_AGENT_RESPONSE_CREATOR_H
9 
10 #include <agent/ca_command_mgr.h>
11 #include <http/response_creator.h>
12 #include <boost/shared_ptr.hpp>
13 
14 namespace isc {
15 namespace agent {
16 
18 
20 typedef boost::shared_ptr<CtrlAgentResponseCreator> CtrlAgentResponseCreatorPtr;
21 
37 public:
38 
47 
54  virtual http::HttpResponsePtr
56  const http::HttpStatusCode& status_code) const;
57 
58 private:
59 
71  createStockHttpResponseInternal(const http::HttpRequestPtr& request,
72  const http::HttpStatusCode& status_code) const;
73 
78  virtual http::HttpResponsePtr
79  createDynamicHttpResponse(http::HttpRequestPtr request);
80 };
81 
82 } // end of namespace isc::agent
83 } // end of namespace isc
84 
85 #endif
Specifies an interface for classes creating HTTP responses from HTTP requests.
boost::shared_ptr< HttpResponse > HttpResponsePtr
Pointer to the HttpResponse object.
Definition: response.h:78
Defines the logger used by the top-level component of kea-lfc.
Concrete implementation of the HTTP response creator used by the Control Agent.
boost::shared_ptr< HttpRequest > HttpRequestPtr
Pointer to the HttpRequest object.
Definition: request.h:27
boost::shared_ptr< CtrlAgentResponseCreator > CtrlAgentResponseCreatorPtr
Pointer to the CtrlAgentResponseCreator.
virtual http::HttpRequestPtr createNewHttpRequest() const
Create a new request.
HttpStatusCode
HTTP status codes (cf RFC 2068)
Definition: response.h:30
virtual http::HttpResponsePtr createStockHttpResponse(const http::HttpRequestPtr &request, const http::HttpStatusCode &status_code) const
Creates stock HTTP response.