Class DefaultAlertMessage
java.lang.Object
com.inductiveautomation.ignition.gateway.alert.DefaultAlertMessage
- All Implemented Interfaces:
- AlertMessage,- Serializable
A simple immutable implementation of AlertMessage
- See Also:
- 
Field SummaryFields inherited from interface com.inductiveautomation.ignition.common.alert.AlertMessageACKNOWLEDGED, ACTIVE, CLEARED, DEREGISTER, INFO_UPDATE, REGISTER, SUPPRESS_CLEAR_MSG
- 
Constructor SummaryConstructorsConstructorDescriptionDefaultAlertMessage(String system, String path, String stateName, AlertSeverity stateSeverity, Double value, Date timestamp, boolean register, boolean active, boolean cleared, boolean acknowledged, String user, String message, String displayPath, String notes, AlertNotificationMode notificationMode) DefaultAlertMessage(Date timeStamp) 
- 
Method SummaryModifier and TypeMethodDescriptionintReturns the alert flags to determine what type of alert it is.
 REGISTER - 0x00000001 ACTIVE - 0x00000010 CLEARED - 0x00000100 ACKNOWLEDGED - 0x00001000 DEREGISTER - 0x00010000 SUPPRESS_CLEAR_MSG - 0x00010000Returns a user-configurable "friendly" path for the alert.Returns the alert's custom message, if any.Returns the alerts custom subject, if any.getNotes()Get alert notes (extra information about the alert).Returns the notification mode for the tag- when it wants notifications to occur.getPath()Returns the path of the source, such as the path to a SQLTag, which should be reasonably unique.Returns the name of the alert state that was triggeredReturns the severity of the alert stateReturns the name of the SCADARail system responsible for the alertReturns the originating timestamp for the message.getUser()Returns a username associated with the message.getValue()Returns the value that caused this alert.booleanReturns whether or not the message is flagged as ACKNOWLEDGEDbooleanisActive()Returns whether or not the message is flagged as ACTIVEbooleanReturns whether or not the message is flagged as CLEAREDbooleanReturns whether or not the message is flagged as DEREGISTERbooleanReturns whether or not the message is flagged as REGISTERbooleanisUpdate()voidsetAlertFlag(int flag) Sets an alert flag to on status.voidsetAlertFlag(int flag, boolean value) Sets an alert flag to on or off status depending on value.voidsetDisplayPath(String displayPath) voidsetMessage(String message) voidsetMessageSubject(String value) voidvoidsetNotificationMode(AlertNotificationMode notificationMode) voidvoidsetStateName(String stateName) voidsetStateSeverity(AlertSeverity stateSeverity) voidvoidsetTimestamp(Date timestamp) voidvoidbooleanReturns whether or not the message is flagged as SUPPRESS_CLEAR_MSGtoString()
- 
Constructor Details- 
DefaultAlertMessagepublic DefaultAlertMessage()
- 
DefaultAlertMessage
- 
DefaultAlertMessage
- 
DefaultAlertMessagepublic DefaultAlertMessage(String system, String path, String stateName, AlertSeverity stateSeverity, Double value, Date timestamp, boolean register, boolean active, boolean cleared, boolean acknowledged, String user, String message, String displayPath, String notes, AlertNotificationMode notificationMode) 
 
- 
- 
Method Details- 
getAlertFlagspublic int getAlertFlags()Description copied from interface:AlertMessageReturns the alert flags to determine what type of alert it is.
 - REGISTER - 0x00000001
- ACTIVE - 0x00000010
- CLEARED - 0x00000100
- ACKNOWLEDGED - 0x00001000
- DEREGISTER - 0x00010000
- SUPPRESS_CLEAR_MSG - 0x00010000
 - Specified by:
- getAlertFlagsin interface- AlertMessage
 
- 
setAlertFlagpublic void setAlertFlag(int flag) Sets an alert flag to on status.
- 
setAlertFlagpublic void setAlertFlag(int flag, boolean value) Sets an alert flag to on or off status depending on value.
- 
getMessageSubjectDescription copied from interface:AlertMessageReturns the alerts custom subject, if any.- Specified by:
- getMessageSubjectin interface- AlertMessage
 
- 
setMessageSubject
- 
getMessageDescription copied from interface:AlertMessageReturns the alert's custom message, if any.- Specified by:
- getMessagein interface- AlertMessage
 
- 
setMessage
- 
getNotesDescription copied from interface:AlertMessageGet alert notes (extra information about the alert).- Specified by:
- getNotesin interface- AlertMessage
 
- 
setNotes
- 
getPathDescription copied from interface:AlertMessageReturns the path of the source, such as the path to a SQLTag, which should be reasonably unique. That is, there should not be another alert with the same path in the same SCADARail system. This path lets alert handlers correlate ACKS and CLEARS with their initial ALERTs- Specified by:
- getPathin interface- AlertMessage
 
- 
setPath
- 
getDisplayPathDescription copied from interface:AlertMessageReturns a user-configurable "friendly" path for the alert. Configured on the tag level (so will likely be used often along with state name).- Specified by:
- getDisplayPathin interface- AlertMessage
 
- 
setDisplayPath
- 
getStateNameDescription copied from interface:AlertMessageReturns the name of the alert state that was triggered- Specified by:
- getStateNamein interface- AlertMessage
 
- 
setStateName
- 
getStateSeverityDescription copied from interface:AlertMessageReturns the severity of the alert state- Specified by:
- getStateSeverityin interface- AlertMessage
 
- 
setStateSeverity
- 
getSystemDescription copied from interface:AlertMessageReturns the name of the SCADARail system responsible for the alert- Specified by:
- getSystemin interface- AlertMessage
 
- 
setSystem
- 
getTimestampDescription copied from interface:AlertMessageReturns the originating timestamp for the message.- Specified by:
- getTimestampin interface- AlertMessage
 
- 
setTimestamp
- 
getUserDescription copied from interface:AlertMessageReturns a username associated with the message. Mostly used for Acknowledegments- Specified by:
- getUserin interface- AlertMessage
 
- 
setUser
- 
getValueDescription copied from interface:AlertMessageReturns the value that caused this alert. May not be applicable for all message types- Specified by:
- getValuein interface- AlertMessage
 
- 
setValue
- 
getNotificationModeDescription copied from interface:AlertMessageReturns the notification mode for the tag- when it wants notifications to occur.- Specified by:
- getNotificationModein interface- AlertMessage
 
- 
setNotificationMode
- 
isAcknowledgedpublic boolean isAcknowledged()Description copied from interface:AlertMessageReturns whether or not the message is flagged as ACKNOWLEDGED- Specified by:
- isAcknowledgedin interface- AlertMessage
 
- 
isActivepublic boolean isActive()Description copied from interface:AlertMessageReturns whether or not the message is flagged as ACTIVE- Specified by:
- isActivein interface- AlertMessage
 
- 
isClearedpublic boolean isCleared()Description copied from interface:AlertMessageReturns whether or not the message is flagged as CLEARED- Specified by:
- isClearedin interface- AlertMessage
 
- 
isRegisterpublic boolean isRegister()Description copied from interface:AlertMessageReturns whether or not the message is flagged as REGISTER- Specified by:
- isRegisterin interface- AlertMessage
 
- 
isDeregisterpublic boolean isDeregister()Description copied from interface:AlertMessageReturns whether or not the message is flagged as DEREGISTER- Specified by:
- isDeregisterin interface- AlertMessage
 
- 
suppressClearMessagepublic boolean suppressClearMessage()Description copied from interface:AlertMessageReturns whether or not the message is flagged as SUPPRESS_CLEAR_MSG- Specified by:
- suppressClearMessagein interface- AlertMessage
 
- 
isUpdatepublic boolean isUpdate()- Specified by:
- isUpdatein interface- AlertMessage
 
- 
toString
 
-