1 /*
2 // Copyright (c) 2018 Intel Corporation
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 //      http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 */
16 #pragma once
17 
18 #include "conf.hpp"
19 
20 #include <boost/asio/steady_timer.hpp>
21 #include <sdbusplus/bus.hpp>
22 
23 #include <cstdint>
24 #include <string>
25 #include <unordered_map>
26 #include <variant>
27 #include <vector>
28 
29 using DbusVariantType =
30     std::variant<uint64_t, int64_t, double, std::string,
31                  std::vector<std::string>, std::vector<double>>;
32 
33 using ManagedObjectType = std::unordered_map<
34     sdbusplus::message::object_path,
35     std::unordered_map<std::string,
36                        std::unordered_map<std::string, DbusVariantType>>>;
37 
38 namespace pid_control
39 {
40 namespace dbus_configuration
41 {
42 bool init(sdbusplus::bus::bus& bus, boost::asio::steady_timer& timer);
43 } // namespace dbus_configuration
44 } // namespace pid_control
45