public class AlarmStateStatistics
extends java.lang.Object
AlarmStateStatistics
class is designed to calculate
alarm state of elements in connected data box.Modifier and Type | Field and Description |
---|---|
protected java.beans.PropertyChangeSupport |
propertyChangeSupport |
Constructor and Description |
---|
AlarmStateStatistics()
Creates a
AlarmStateStatistics instance with a default
data box created inside the initialization. |
AlarmStateStatistics(TDataBox box)
Creates a a
AlarmStateStatistics instance with a given data box object. |
AlarmStateStatistics(TDataBox box,
java.util.List alarmSeverities)
Creates a a
AlarmStateStatistics instance with a given data box object. |
Modifier and Type | Method and Description |
---|---|
protected void |
fireAlarmStateChange()
Fire alarm state change event.
|
protected void |
firePropertyChange(java.lang.String propertyName,
java.lang.Object oldValue,
java.lang.Object newValue) |
int |
getAcknowledgedAlarmCount()
Gets the acknowledged alarm count of elements in connected data box.
|
int |
getAcknowledgedAlarmCount(AlarmSeverity severity)
Get acknowledged alarm count for specified alarm severity.
|
TDataBox |
getDataBox()
Gets the connected data box.
|
int |
getNewAlarmCount()
Gets the new alarm count of elements in connected data box.
|
int |
getNewAlarmCount(AlarmSeverity severity)
Get new alarm count for specified alarm severity.
|
java.beans.PropertyChangeSupport |
getPropertyChangeSupport() |
java.util.List |
getSeverityList()
Gets a list contains all alarm severities that are interested.
|
int |
getTotalAlarmCount()
Gets the total alarm count of elements in connected data box,
including new and acknowledged alarm.
|
int |
getTotalAlarmCount(AlarmSeverity severity)
Get alarm total count for specified alarm severity.
|
VisibleFilter |
getVisibleFilter()
Gets the visible filter for this alarm statistic.
|
boolean |
isVisible(Element element)
Checks whether the given element is needed to be calculated
for this alarm statistic.
|
void |
reset()
Calls this method to recalculate all alarm count of elements in data box.
|
void |
setDataBox(TDataBox box)
Sets a new data box for this alarm state statistic.
|
void |
setVisibleFilter(VisibleFilter visibleFilter)
Sets a new visible filter for this alarm statistic.
|
public AlarmStateStatistics()
AlarmStateStatistics
instance with a default
data box created inside the initialization.public AlarmStateStatistics(TDataBox box)
AlarmStateStatistics
instance with a given data box object.box
- the connected data box object.public AlarmStateStatistics(TDataBox box, java.util.List alarmSeverities)
AlarmStateStatistics
instance with a given data box object.box
- the connected data box object.alarmSeverities
- a list contains alarm severities that need to be calculated.public java.beans.PropertyChangeSupport getPropertyChangeSupport()
protected void firePropertyChange(java.lang.String propertyName, java.lang.Object oldValue, java.lang.Object newValue)
public TDataBox getDataBox()
public void setDataBox(TDataBox box)
box
- a new data box to be calculated.protected void fireAlarmStateChange()
public int getNewAlarmCount()
public int getTotalAlarmCount()
public int getAcknowledgedAlarmCount()
public int getTotalAlarmCount(AlarmSeverity severity)
severity
- AlarmSeverity an alarm severity to be calculatepublic int getNewAlarmCount(AlarmSeverity severity)
severity
- AlarmSeverity alarm severity to be checkgetAcknowledgedAlarmCount()
public int getAcknowledgedAlarmCount(AlarmSeverity severity)
severity
- AlarmSeverity alarm severity to be checkgetNewAlarmCount()
public void reset()
public VisibleFilter getVisibleFilter()
public void setVisibleFilter(VisibleFilter visibleFilter)
visibleFilter
- a new visible filter.public boolean isVisible(Element element)
element
- the element to be checked.public java.util.List getSeverityList()
Copyright © 2002 - 2010 Serva Software. All Rights Reserved.