blob: f45c91007b0e9ea14db22cec9f94c8cd1cfd8184 [file] [log] [blame]
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -05001#pragma once
2
George Liudc746c02022-09-02 11:10:55 +08003#include "utils.hpp"
4
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -05005#include <sdbusplus/bus.hpp>
George Liuc6d33972020-06-22 10:35:29 +08006
Gunnar Millsab4cc6a2018-09-14 14:42:39 -05007#include <string>
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -05008
9namespace settings
10{
11
George Liudc746c02022-09-02 11:10:55 +080012using namespace phosphor::time::utils;
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -050013
14constexpr auto root = "/";
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -050015constexpr auto timeSyncIntf = "xyz.openbmc_project.Time.Synchronization";
16
17/** @class Objects
18 * @brief Fetch paths of settings D-bus objects of interest upon construction
19 */
20struct Objects
21{
Gunnar Millsab4cc6a2018-09-14 14:42:39 -050022 public:
23 /** @brief Constructor - fetch settings objects
24 *
25 * @param[in] bus - The D-bus bus object
26 */
Brad Bishop4e845392018-12-18 18:13:12 -050027 Objects() = delete;
Patrick Williams38679262022-07-22 19:26:55 -050028 explicit Objects(sdbusplus::bus_t&);
Brad Bishop4e845392018-12-18 18:13:12 -050029 Objects(const Objects&) = delete;
30 Objects& operator=(const Objects&) = delete;
Gunnar Millsab4cc6a2018-09-14 14:42:39 -050031 Objects(Objects&&) = default;
32 Objects& operator=(Objects&&) = default;
33 ~Objects() = default;
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -050034
Gunnar Millsab4cc6a2018-09-14 14:42:39 -050035 /** @brief time sync method settings object */
36 Path timeSyncMethod;
Lei YUdebe1d82017-10-13 13:21:37 +080037
Brad Bishop4e845392018-12-18 18:13:12 -050038 private:
Patrick Williams38679262022-07-22 19:26:55 -050039 sdbusplus::bus_t& bus;
Deepak Kodihalli20ed79e2017-07-25 05:48:58 -050040};
41
42} // namespace settings