| Kea 3.0.2-git

ca_controller.h
Go to the documentation of this file.
1// Copyright (C) 2016-2017 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_CONTROLLER_H
8#define CTRL_AGENT_CONTROLLER_H
9
10#include <agent/ca_process.h>
11#include <process/d_controller.h>
12
13 namespace isc {
14 namespace agent {
15
21 class CtrlAgentController : public process::DControllerBase {
22 public:
23
31 static process::DControllerBasePtr& instance();
32
34 virtual ~CtrlAgentController();
35
37 CtrlAgentProcessPtr getCtrlAgentProcess();
38
41 static const char* agent_app_name_;
42
45 static const char* agent_bin_name_;
46
51 isc::data::ConstElementPtr
52 parseFile(const std::string& name);
53
55 void registerCommands();
56
58 void deregisterCommands();
59
60 private:
61
72 virtual process::DProcessBase* createProcess();
73
76 CtrlAgentController();
77};
78
79// @Defines a shared pointer to CtrlAgentController
80 typedef boost::shared_ptr<CtrlAgentController> CtrlAgentControllerPtr;
81
82} // namespace isc::agent
83} // namespace isc
84
85#endif // CTRL_AGENT_CONTROLLER_H
ca_process.h
isc::agent::CtrlAgentController::instance
static process::DControllerBasePtr & instance()
Static singleton instance method.
Definition ca_controller.cc:30
isc::agent::CtrlAgentController::deregisterCommands
void deregisterCommands()
Deregister commands.
Definition ca_controller.cc:88
isc::agent::CtrlAgentController::parseFile
isc::data::ConstElementPtr parseFile(const std::string &name)
Parses the configuration file using Agent::ParserContext (bison).
Definition ca_controller.cc:49
isc::agent::CtrlAgentController::agent_bin_name_
static const char * agent_bin_name_
Defines the executable name.
Definition ca_controller.h:45
isc::agent::CtrlAgentController::registerCommands
void registerCommands()
Register commands.
Definition ca_controller.cc:55
isc::agent::CtrlAgentController::~CtrlAgentController
virtual ~CtrlAgentController()
Destructor.
Definition ca_controller.cc:105
isc::agent::CtrlAgentController::getCtrlAgentProcess
CtrlAgentProcessPtr getCtrlAgentProcess()
Returns pointer to an instance of the underlying process object.
Definition ca_controller.cc:109
isc::agent::CtrlAgentController::agent_app_name_
static const char * agent_app_name_
Defines the application name, this is passed into base class and appears in log statements.
Definition ca_controller.h:41
isc::process::DControllerBase
Application Controller.
Definition d_controller.h:103
isc::process::DControllerBase::createProcess
virtual DProcessBase * createProcess()=0
Abstract method that is responsible for instantiating the application process object.
isc::process::DProcessBase
Application Process Interface.
Definition d_process.h:75
d_controller.h
isc::agent
Definition agent_parser.cc:148
isc::agent::CtrlAgentProcessPtr
boost::shared_ptr< CtrlAgentProcess > CtrlAgentProcessPtr
Defines a shared pointer to CtrlAgentProcess.
Definition ca_process.h:164
isc::agent::CtrlAgentControllerPtr
boost::shared_ptr< CtrlAgentController > CtrlAgentControllerPtr
Definition ca_controller.h:80
isc::data::ConstElementPtr
boost::shared_ptr< const Element > ConstElementPtr
Definition data.h:29
isc::process::DControllerBasePtr
boost::shared_ptr< DControllerBase > DControllerBasePtr
Definition d_controller.h:78
isc
Defines the logger used by the top-level component of kea-lfc.
Definition agent_parser.cc:148