@Mixins(value=AlarmHistory.AlarmHistoryMixin.class) public interface AlarmHistory
AlarmHistory classes to
record the events of an AlarmPoint.| Modifier and Type | Interface and Description |
|---|---|
static class |
AlarmHistory.AlarmHistoryMixin |
| Modifier and Type | Method and Description |
|---|---|
int |
activateCounter()
Returns the Counter of activate triggers.
|
void |
addEvent(AlarmEvent event,
String trigger) |
Property<List<AlarmEvent>> |
allAlarmEvents()
Returns a
java.util.List of all recorded AlarmEvents. |
Property<Map<String,Integer>> |
counters()
Returns all the Counters of triggers.
|
AlarmEvent |
eventAt(int position)
Returns the recorded
AlarmEvent at the given position
in the buffer. |
AlarmEvent |
eventAtEnd(int position)
Returns the recorded
AlarmEvent at the given position
in the buffer counted from the end. |
AlarmEvent |
firstEvent()
Returns the oldest recorded
AlarmEvent. |
AlarmEvent |
lastEvent()
Returns the newest recorded
AlarmEvent. |
Property<Integer> |
maxSize()
The maximum size of the history buffer.
|
void |
resetActivateCounter()
Resets the Activate counter.
|
void |
resetAllCounters()
Resets all counters.
|
AlarmEvent lastEvent()
AlarmEvent.AlarmEvent firstEvent()
AlarmEvent.AlarmEvent eventAt(int position)
AlarmEvent at the given position
in the buffer.position - the position in the buffer, counted from the beginning to obtain the AlarmEvent from.
0 means the first element.AlarmEvent at the given position in the buffer.AlarmEvent eventAtEnd(int position)
AlarmEvent at the given position
in the buffer counted from the end.position - the position in the buffer, counted from the end to obtain the AlarmEvent from.
0 means the last element.AlarmEvent at the given position in the buffer counted from the end.@UseDefaults Property<List<AlarmEvent>> allAlarmEvents()
java.util.List of all recorded AlarmEvents.java.util.List of all recorded AlarmEvents.@UseDefaults Property<Integer> maxSize()
AlarmEvents should be removed
so that the number of stored events are equal to the new MaxSize.@UseDefaults Property<Map<String,Integer>> counters()
trigger() method is called,
a Counter is incremented. That means that after the first
time the following the sequence is called
activate();
acknowledge();
deactivate();
, the Map contains
| (String) activate | (Integer) 1 |
| (String) deactivate | (Integer) 1 |
| (String) acknowledge | (Integer) 1 |
void resetAllCounters()
int activateCounter()
activate() method and the trigger()
method with an activate trigger is called.void resetActivateCounter()
void addEvent(AlarmEvent event, String trigger)