Package org.opennms.netmgt.alarmd.api
Class AlarmCallbackStateTracker
- java.lang.Object
-
- org.opennms.netmgt.alarmd.api.AlarmCallbackStateTracker
-
public class AlarmCallbackStateTracker extends Object
This class can be used to help track callbacks issued via theAlarmLifecycleListener
in order to help simplify possible synchronization logic inAlarmLifecycleListener.handleAlarmSnapshot(List)
.- Author:
- jwhite
-
-
Constructor Summary
Constructors Constructor Description AlarmCallbackStateTracker()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<Integer>
getUpdatedAlarmIds()
void
resetStateAndStopTrackingAlarms()
void
startTrackingAlarms()
void
trackDeletedAlarm(int alarmId, String reductionKey)
void
trackNewOrUpdatedAlarm(int alarmId, String reductionKey)
boolean
wasAlarmWithIdDeleted(int alarmId)
boolean
wasAlarmWithIdUpdated(int alarmId)
boolean
wasAlarmWithReductionKeyDeleted(String reductionKey)
boolean
wasAlarmWithReductionKeyUpdated(String reductionKey)
-
-
-
Method Detail
-
startTrackingAlarms
public void startTrackingAlarms()
-
trackNewOrUpdatedAlarm
public void trackNewOrUpdatedAlarm(int alarmId, String reductionKey)
-
trackDeletedAlarm
public void trackDeletedAlarm(int alarmId, String reductionKey)
-
resetStateAndStopTrackingAlarms
public void resetStateAndStopTrackingAlarms()
-
wasAlarmWithIdUpdated
public boolean wasAlarmWithIdUpdated(int alarmId)
-
wasAlarmWithIdDeleted
public boolean wasAlarmWithIdDeleted(int alarmId)
-
wasAlarmWithReductionKeyUpdated
public boolean wasAlarmWithReductionKeyUpdated(String reductionKey)
-
wasAlarmWithReductionKeyDeleted
public boolean wasAlarmWithReductionKeyDeleted(String reductionKey)
-
-