org.csstudio.data.values
Interface ISeverity
- All Superinterfaces:
- java.io.Serializable
public interface ISeverity
- extends java.io.Serializable
Description of the 'severity' of a value.
The severity code is usually meant to indicate if the process variable
that provided a value was 'ok', or in various states of warning or error.
Different implementations might have more or fewer warning and error states.
To allow the implementation of generic tools, we define generic
states 'OK', 'Minor', 'Major' and 'Invalid' as follows:
- OK - The 'normal' severity, indicating that the process variable is
fine.
- Minor - A severity that indicates a minor warning. The process variable
is valid, but its value might be close to some trip threshold.
Some applications might indicate this by displaying the value
in yellow.
- Major - A severity that indicates a major warning. The process variable
is valid, but its value might have exceeded some trip threshold.
Some applications might indicate this by displaying the value
in red.
- Invalid - A severity that indicates an error. The process variable
is probably invalid. The value could be a bad or old reading,
Some applications might indicate this by displaying the value
in grey.
- Author:
- Kay Kasemir
toString
java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
- Returns:
- Returns the textual representation for this severity.
isOK
boolean isOK()
- Returns:
- Returns
true
if this severity is in
the 'OK' category.
isMinor
boolean isMinor()
- Returns:
- Returns
true
if this severity is in
the 'Minor' category.
isMajor
boolean isMajor()
- Returns:
- Returns
true
if this severity is in
the 'Major' category.
isInvalid
boolean isInvalid()
- Returns:
- Returns
true
if this severity is in
the 'Invalid' category.
hasValue
boolean hasValue()
- Returns:
- Returns
true
if the associated value is meaningful,
false
if the value represents for example a 'disconnected'
state and thus has no numeric value.