blob: 74fcc4b7d70d4c8f4f95fe985661c11505229e63 [file] [log] [blame]
Adriana Kobylak88d7cf82017-01-24 12:30:15 -06001#include "elog_entry.hpp"
Deepak Kodihalli36db46c2017-03-31 06:28:44 -05002#include "log_manager.hpp"
Deepak Kodihalli97431892017-06-12 09:14:57 -05003#include "elog_serialize.hpp"
Adriana Kobylak88d7cf82017-01-24 12:30:15 -06004
5namespace phosphor
6{
7namespace logging
8{
9
Adriana Kobylak88d7cf82017-01-24 12:30:15 -060010// TODO Add interfaces to handle the error log id numbering
11
Deepak Kodihalli36db46c2017-03-31 06:28:44 -050012void Entry::delete_()
13{
14 parent.erase(id());
15}
16
Deepak Kodihalli97431892017-06-12 09:14:57 -050017bool Entry::resolved(bool value)
18{
19 auto current = sdbusplus::xyz::openbmc_project::
20 Logging::server::Entry::resolved();
21 if (value != current)
22 {
23 value ?
24 associations({}) :
25 associations(assocs);
26 current = sdbusplus::xyz::openbmc_project::
27 Logging::server::Entry::resolved(value);
28 serialize(*this);
29 }
30
31 return current;
32}
33
Adriana Kobylak88d7cf82017-01-24 12:30:15 -060034} // namespace logging
35} // namepsace phosphor