1 #pragma once
2 
3 #include <cstdint>
4 #include <functional>
5 #include <map>
6 #include <sdbusplus/message/types.hpp>
7 #include <string>
8 
9 namespace sdbusplus
10 {
11 namespace message
12 {
13 class message;
14 }
15 namespace bus
16 {
17 class bus;
18 }
19 } // namespace sdbusplus
20 
21 namespace phosphor
22 {
23 namespace inventory
24 {
25 namespace manager
26 {
27 
28 class Manager;
29 
30 /** @brief Inventory manager supported property types. */
31 using InterfaceVariantType =
32     sdbusplus::message::variant_ns::variant<bool, int64_t, std::string>;
33 
34 template <typename T>
35 using InterfaceType = std::map<std::string, T>;
36 
37 template <typename T>
38 using ObjectType = std::map<std::string, InterfaceType<T>>;
39 
40 using Interface = InterfaceType<InterfaceVariantType>;
41 using Object = ObjectType<InterfaceVariantType>;
42 
43 using Action = std::function<void(sdbusplus::bus::bus&, Manager&)>;
44 using Filter = std::function<bool(sdbusplus::bus::bus&,
45                                   sdbusplus::message::message&, Manager&)>;
46 using PathCondition =
47     std::function<bool(const std::string&, sdbusplus::bus::bus&, Manager&)>;
48 template <typename T>
49 using GetProperty = std::function<T(Manager&)>;
50 } // namespace manager
51 } // namespace inventory
52 } // namespace phosphor
53 
54 // vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4
55