Ejemplo n.º 1
0
 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();
       }
     }
   }
 }
  public EventBuilder addParam(final Parm parm) {
    m_event.addParm(parm);

    return this;
  }