| 131 | } |
| 132 | |
| 133 | void Notification::EvaluateApplyRules(const Host::Ptr& host) |
| 134 | { |
| 135 | CONTEXT("Evaluating 'apply' rules for host '" << host->GetName() << "'"); |
| 136 | |
| 137 | for (auto& rule : ApplyRule::GetRules(Notification::TypeInstance, Host::TypeInstance)) |
| 138 | { |
| 139 | if (EvaluateApplyRule(host, *rule)) |
| 140 | rule->AddMatch(); |
| 141 | } |
| 142 | |
| 143 | for (auto& rule : ApplyRule::GetTargetedHostRules(Notification::TypeInstance, host->GetName())) { |
| 144 | if (EvaluateApplyRule(host, *rule, true)) |
| 145 | rule->AddMatch(); |
| 146 | } |
| 147 | } |
| 148 | |
| 149 | void Notification::EvaluateApplyRules(const Service::Ptr& service) |
| 150 | { |