summaryrefslogtreecommitdiffstats
path: root/elog_entry.cpp
blob: 04aa9171c1933a7a4b3543db8061865e18945805 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#include "elog_entry.hpp"

#include "elog_serialize.hpp"
#include "log_manager.hpp"

namespace phosphor
{
namespace logging
{

// TODO Add interfaces to handle the error log id numbering

void Entry::delete_()
{
    parent.erase(id());
}

bool Entry::resolved(bool value)
{
    auto current =
        sdbusplus::xyz::openbmc_project::Logging::server::Entry::resolved();
    if (value != current)
    {
        value ? associations({}) : associations(assocs);
        current =
            sdbusplus::xyz::openbmc_project::Logging::server::Entry::resolved(
                value);
        serialize(*this);
    }

    return current;
}

} // namespace logging
} // namespace phosphor
OpenPOWER on IntegriCloud