Kea 3.1.1
log_parser.h
Go to the documentation of this file.
1// Copyright (C) 2014-2025 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 DHCPSRV_LOGGING_H
8#define DHCPSRV_LOGGING_H
9
10#include <cc/data.h>
12#include <process/config_base.h>
13#include <vector>
14
15namespace isc {
16namespace process {
17
44public:
45
49 LogConfigParser(const ConfigPtr& storage);
50
59 bool verbose = false);
60
73 static std::string getLogPath(bool reset = false, const std::string explicit_path = "");
74
80 static std::string validatePath(const std::string logpath);
81
82private:
83
88 void parseConfigEntry(isc::data::ConstElementPtr entry);
89
96 void parseOutputOptions(std::vector<LoggingDestination>& destination,
97 isc::data::ConstElementPtr output_options);
98
102 ConfigPtr config_;
103
108 bool verbose_;
109};
110
111} // namespace isc::dhcp
112} // namespace isc
113
114#endif // DHCPSRV_LOGGING_H
LogConfigParser(const ConfigPtr &storage)
Constructor.
Definition log_parser.cc:30
static std::string getLogPath(bool reset=false, const std::string explicit_path="")
Fetches the supported log file path.
static std::string validatePath(const std::string logpath)
Validates a library path against the supported path for log files.
void parseConfiguration(const isc::data::ConstElementPtr &log_config, bool verbose=false)
Parses specified configuration.
Definition log_parser.cc:38
boost::shared_ptr< const Element > ConstElementPtr
Definition data.h:29
boost::shared_ptr< ConfigBase > ConfigPtr
Non-const pointer to the ConfigBase.
Defines the logger used by the top-level component of kea-lfc.