1 #pragma once
2 
3 #include <sdbusplus/bus.hpp>
4 
5 #include <string>
6 
7 namespace openpower
8 {
9 namespace util
10 {
11 /**
12  * Get D-Bus service name for the specified object and interface
13  *
14  * @param[in] bus - sdbusplus D-Bus to attach to
15  * @param[in] objectPath - D-Bus object path
16  * @param[in] interface - D-Bus interface name
17  *
18  * @return service name on success and exception on failure
19  */
20 std::string getService(sdbusplus::bus::bus& bus, const std::string& objectPath,
21                        const std::string& interface);
22 
23 /**
24  * Returns true if host is in poweringoff state else false
25  *
26  * @return bool - true if host is powering off else false. if failed
27  *  to read property false will be returned.
28  */
29 bool isHostPoweringOff();
30 
31 } // namespace util
32 } // namespace openpower
33