diff options
author | Deepak Kodihalli <dkodihal@in.ibm.com> | 2017-02-27 00:47:12 -0600 |
---|---|---|
committer | Deepak Kodihalli <dkodihal@in.ibm.com> | 2017-03-15 09:20:14 -0500 |
commit | b388da6553fac65a50ce02ca4d87b31fb5c9faeb (patch) | |
tree | 1aac6fb762b248c5105bff26579a8c85ecf44af3 /elog_entry.hpp | |
parent | 867f7aa7098ebcc3f62fec7faa6121390d1bd055 (diff) | |
download | phosphor-logging-b388da6553fac65a50ce02ca4d87b31fb5c9faeb.tar.gz phosphor-logging-b388da6553fac65a50ce02ca4d87b31fb5c9faeb.zip |
Entry: implement org.openbmc.Associations API
Have the Entry object implement the org.openbmc.Associations DBus API in
order to add inventory callouts to errors.
Change-Id: I9c645c90e3de4601cdbb020b591f5da24c733613
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
Diffstat (limited to 'elog_entry.hpp')
-rw-r--r-- | elog_entry.hpp | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/elog_entry.hpp b/elog_entry.hpp index 76e51cf..5968145 100644 --- a/elog_entry.hpp +++ b/elog_entry.hpp @@ -3,28 +3,24 @@ #include <sdbusplus/bus.hpp> #include <sdbusplus/server/object.hpp> #include "xyz/openbmc_project/Logging/Entry/server.hpp" +#include "org/openbmc/Associations/server.hpp" namespace phosphor { namespace logging { -namespace details -{ - -template <typename T> -using ServerObject = typename sdbusplus::server::object::object<T>; - -using EntryIface = - sdbusplus::xyz::openbmc_project::Logging::server::Entry; -} // namespace details +using EntryIfaces = sdbusplus::server::object::object< + sdbusplus::xyz::openbmc_project::Logging::server::Entry, + sdbusplus::org::openbmc::server::Associations>; /** @class Entry * @brief OpenBMC logging entry implementation. * @details A concrete implementation for the - * xyz.openbmc_project.Logging.Entry DBus API. + * xyz.openbmc_project.Logging.Entry and + * org.openbmc.Associations DBus APIs. */ -class Entry : public details::ServerObject<details::EntryIface> +class Entry : public EntryIfaces { public: Entry() = delete; @@ -52,8 +48,7 @@ class Entry : public details::ServerObject<details::EntryIface> Level severityErr, std::string&& msgErr, std::vector<std::string>&& additionalDataErr) : - details::ServerObject<details::EntryIface> - (bus, path.c_str(), true) + EntryIfaces(bus, path.c_str(), true) { id(idErr); severity(severityErr); |