#include #include "conditions.hpp" #include "sdbusplus.hpp" namespace phosphor { namespace fan { namespace monitor { namespace condition { Condition propertiesMatch(std::vector&& propStates) { return [pStates = std::move(propStates)](sdbusplus::bus::bus& bus) { return std::all_of( pStates.begin(), pStates.end(), [&bus](const auto& p) { return util::SDBusPlus::getPropertyVariant( bus, std::get(p.first), std::get(p.first), std::get(p.first)) == p.second; }); }; } } // namespace condition } // namespace monitor } // namespace fan } // namespace phosphor