use of org.opennms.netmgt.xml.event.Value in project opennms by OpenNMS.
the class ThresholdEntity method sendRearmForTriggeredStates.
private void sendRearmForTriggeredStates() {
for (String instance : m_thresholdEvaluatorStates.keySet()) {
for (ThresholdEvaluatorState state : m_thresholdEvaluatorStates.get(instance)) {
if (state.isTriggered()) {
Event e = state.getEventForState(Status.RE_ARMED, new Date(), Double.NaN, null);
Parm p = new Parm();
p.setParmName("reason");
Value v = new Value();
v.setContent("Configuration has been changed");
p.setValue(v);
e.addParm(p);
LOG.info("sendRearmForTriggeredStates: sending rearm for {}", e);
ThresholdingEventProxyFactory.getFactory().getProxy().add(e);
state.clearState();
}
}
}
}
use of org.opennms.netmgt.xml.event.Value in project opennms by OpenNMS.
the class PassiveStatusKeeperIT method buildParm.
private Parm buildParm(String parmName, String parmValue) {
Value v = new Value();
v.setContent(parmValue);
Parm p = new Parm();
p.setParmName(parmName);
p.setValue(v);
return p;
}
use of org.opennms.netmgt.xml.event.Value in project opennms by OpenNMS.
the class EventTranslatorIT method buildParm.
private Parm buildParm(String parmName, String parmValue) {
Value v = new Value();
v.setContent(parmValue);
Parm p = new Parm();
p.setParmName(parmName);
p.setValue(v);
return p;
}
Aggregations