Class OnmsAlarm
- java.lang.Object
-
- org.opennms.netmgt.model.OnmsAlarm
-
- All Implemented Interfaces:
java.io.Serializable
,Acknowledgeable
@Entity public class OnmsAlarm extends java.lang.Object implements Acknowledgeable, java.io.Serializable
OnmsAlarm class.
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ARCHIVED
static int
PROBLEM_TYPE
ConstantPROBLEM_TYPE=1
static int
PROBLEM_WITHOUT_RESOLUTION_TYPE
ConstantPROBLEM_WITHOUT_RESOLUTION_TYPE=3
static int
RESOLUTION_TYPE
ConstantRESOLUTION_TYPE=2
-
Constructor Summary
Constructors Constructor Description OnmsAlarm()
default constructorOnmsAlarm(java.lang.Integer alarmid, java.lang.String eventuei, OnmsDistPoller distPoller, java.lang.Integer counter, java.lang.Integer severity, java.util.Date firsteventtime, OnmsEvent event)
minimal constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
acknowledge(java.lang.String user)
acknowledgevoid
addRelatedAlarm(OnmsAlarm alarm)
void
archive()
This marks an alarm as archived and prevents it from being used again in during reduction.void
clear(java.lang.String ackUser)
clearvoid
escalate(java.lang.String ackUser)
escalatejava.util.Optional<OnmsEventParameter>
findEventParameter(java.lang.String name)
java.lang.Integer
getAckId()
getAckIdjava.util.Date
getAckTime()
getAckTimejava.lang.String
getAckUser()
getAckUserjava.lang.Integer
getAffectedNodeCount()
java.util.Date
getAlarmAckTime()
getAlarmAckTimejava.lang.String
getAlarmAckUser()
getAlarmAckUserjava.lang.Integer
getAlarmType()
getAlarmTypejava.lang.String
getApplicationDN()
getApplicationDNjava.util.Set<AlarmAssociation>
getAssociatedAlarms()
java.lang.String
getClearKey()
getClearKeyjava.lang.Integer
getCounter()
getCounterjava.lang.String
getDescription()
getDescriptionjava.util.Map<java.lang.String,java.lang.String>
getDetails()
getDetailsOnmsMonitoringSystem
getDistPoller()
getDistPollerjava.lang.String
getEventParameter(java.lang.String name)
java.util.List<OnmsEventParameter>
getEventParameters()
java.util.Date
getFirstAutomationTime()
getFirstAutomationTimejava.util.Date
getFirstEventTime()
getFirstEventTimejava.lang.Integer
getId()
getIdjava.lang.Integer
getIfIndex()
getIfIndexjava.net.InetAddress
getIpAddr()
getIpAddrjava.util.Date
getLastAutomationTime()
getLastAutomationTimeOnmsEvent
getLastEvent()
getLastEventjava.util.Date
getLastEventTime()
getLastEventTimejava.util.Date
getLastUpdateTime()
java.lang.String
getLogMsg()
getLogMsgjava.lang.String
getManagedObjectInstance()
getManagedObjectInstancejava.lang.String
getManagedObjectType()
getManagedObjectTypejava.lang.String
getMouseOverText()
getMouseOverTextOnmsNode
getNode()
getNodejava.lang.Integer
getNodeId()
java.lang.String
getNodeLabel()
java.lang.String
getOperInstruct()
getOperInstructjava.lang.String
getOssPrimaryKey()
getOssPrimaryKeyjava.lang.String
getQosAlarmState()
getQosAlarmStatejava.lang.String
getReductionKey()
getReductionKeyOnmsReductionKeyMemo
getReductionKeyMemo()
java.util.Set<java.lang.Integer>
getRelatedAlarmIds()
java.util.Set<OnmsAlarm>
getRelatedAlarms()
getRelatedAlarmsjava.util.Set<java.lang.Integer>
getRelatedSituationIds()
java.util.Set<OnmsAlarm>
getRelatedSituations()
OnmsServiceType
getServiceType()
getServiceTypeOnmsSeverity
getSeverity()
getSeverityjava.lang.Integer
getSeverityId()
getSeverityIdjava.lang.String
getSeverityLabel()
getSeverityLabelOnmsMemo
getStickyMemo()
java.util.Date
getSuppressedTime()
getSuppressedTimejava.util.Date
getSuppressedUntil()
getSuppressedUntiljava.lang.String
getSuppressedUser()
getSuppressedUserjava.lang.String
getTTicketId()
getTTicketIdTroubleTicketState
getTTicketState()
getTTicketStateAckType
getType()
getTypejava.lang.String
getUei()
getUeijava.lang.String
getX733AlarmType()
getX733AlarmTypeint
getX733ProbableCause()
getX733ProbableCauseboolean
isAcknowledged()
boolean
isArchived()
boolean
isPartOfSituation()
boolean
isSituation()
void
removeRelatedAlarm(OnmsAlarm alarm)
void
removeRelatedAlarmWithId(java.lang.Integer relatedAlarmId)
void
setAlarmAckTime(java.util.Date alarmacktime)
setAlarmAckTimevoid
setAlarmAckUser(java.lang.String alarmackuser)
setAlarmAckUservoid
setAlarmType(java.lang.Integer alarmtype)
setAlarmTypevoid
setApplicationDN(java.lang.String applicationDN)
setApplicationDNvoid
setAssociatedAlarms(java.util.Set<AlarmAssociation> alarms)
void
setClearKey(java.lang.String clearKey)
setClearKeyvoid
setCounter(java.lang.Integer counter)
setCountervoid
setDescription(java.lang.String description)
setDescriptionvoid
setDetails(java.util.Map<java.lang.String,java.lang.String> alarmDetails)
setDetailsvoid
setDistPoller(OnmsMonitoringSystem distPoller)
setDistPollervoid
setFirstAutomationTime(java.util.Date firstAutomationTime)
setFirstAutomationTimevoid
setFirstEventTime(java.util.Date firsteventtime)
setFirstEventTimevoid
setId(java.lang.Integer alarmid)
setIdvoid
setIfIndex(java.lang.Integer ifIndex)
setIfIndexvoid
setIpAddr(java.net.InetAddress ipaddr)
setIpAddrvoid
setLastAutomationTime(java.util.Date lastAutomationTime)
setLastAutomationTimevoid
setLastEvent(OnmsEvent event)
setLastEventvoid
setLastEventTime(java.util.Date lastEventTime)
setLastEventTimevoid
setLogMsg(java.lang.String logmsg)
setLogMsgvoid
setManagedObjectInstance(java.lang.String managedObjectInstance)
setManagedObjectInstancevoid
setManagedObjectType(java.lang.String managedObjectType)
setManagedObjectTypevoid
setMouseOverText(java.lang.String mouseovertext)
setMouseOverTextvoid
setNode(OnmsNode node)
setNodevoid
setOperInstruct(java.lang.String operinstruct)
setOperInstructvoid
setOssPrimaryKey(java.lang.String key)
setOssPrimaryKeyvoid
setPartOfSituation(boolean partOfSituation)
void
setQosAlarmState(java.lang.String alarmState)
setQosAlarmStatevoid
setReductionKey(java.lang.String reductionkey)
setReductionKeyvoid
setReductionKeyMemo(OnmsReductionKeyMemo reductionKeyMemo)
void
setRelatedAlarms(java.util.Set<OnmsAlarm> alarms)
void
setRelatedAlarms(java.util.Set<OnmsAlarm> alarms, java.util.Date associationEventTime)
void
setRelatedSituations(java.util.Set<OnmsAlarm> alarms)
void
setServiceType(OnmsServiceType service)
setServiceTypevoid
setSeverity(OnmsSeverity severity)
setSeverityvoid
setSeverityId(java.lang.Integer severity)
setSeverityIdvoid
setSeverityLabel(java.lang.String label)
setSeverityLabelvoid
setSituation(boolean situation)
void
setStickyMemo(OnmsMemo stickyMemo)
void
setSuppressedTime(java.util.Date suppressedtime)
setSuppressedTimevoid
setSuppressedUntil(java.util.Date suppresseduntil)
setSuppressedUntilvoid
setSuppressedUser(java.lang.String suppresseduser)
setSuppressedUservoid
setTTicketId(java.lang.String tticketid)
setTTicketIdvoid
setTTicketState(TroubleTicketState tticketstate)
setTTicketStatevoid
setUei(java.lang.String eventuei)
setUeivoid
setX733AlarmType(java.lang.String alarmType)
setX733AlarmTypevoid
setX733ProbableCause(int cause)
setX733ProbableCausejava.lang.String
toString()
toStringvoid
unacknowledge(java.lang.String ackUser)
unacknowledge
-
-
-
Field Detail
-
PROBLEM_TYPE
public static final int PROBLEM_TYPE
ConstantPROBLEM_TYPE=1
- See Also:
- Constant Field Values
-
RESOLUTION_TYPE
public static final int RESOLUTION_TYPE
ConstantRESOLUTION_TYPE=2
- See Also:
- Constant Field Values
-
PROBLEM_WITHOUT_RESOLUTION_TYPE
public static final int PROBLEM_WITHOUT_RESOLUTION_TYPE
ConstantPROBLEM_WITHOUT_RESOLUTION_TYPE=3
- See Also:
- Constant Field Values
-
ARCHIVED
public static final java.lang.String ARCHIVED
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
OnmsAlarm
public OnmsAlarm()
default constructor
-
OnmsAlarm
public OnmsAlarm(java.lang.Integer alarmid, java.lang.String eventuei, OnmsDistPoller distPoller, java.lang.Integer counter, java.lang.Integer severity, java.util.Date firsteventtime, OnmsEvent event)
minimal constructor- Parameters:
alarmid
- aInteger
object.eventuei
- aString
object.distPoller
- aOnmsDistPoller
object.counter
- aInteger
object.severity
- aInteger
object.firsteventtime
- aDate
object.event
- aOnmsEvent
object.
-
-
Method Detail
-
getId
public java.lang.Integer getId()
getId
- Returns:
- a
Integer
object.
-
setId
public void setId(java.lang.Integer alarmid)
setId
- Parameters:
alarmid
- aInteger
object.
-
getUei
public java.lang.String getUei()
getUei
- Returns:
- a
String
object.
-
setUei
public void setUei(java.lang.String eventuei)
setUei
- Parameters:
eventuei
- aString
object.
-
getDistPoller
public OnmsMonitoringSystem getDistPoller()
getDistPoller
- Returns:
- a
OnmsDistPoller
object.
-
setDistPoller
public void setDistPoller(OnmsMonitoringSystem distPoller)
setDistPoller
- Parameters:
distPoller
- aOnmsDistPoller
object.
-
getNode
public OnmsNode getNode()
getNode
- Specified by:
getNode
in interfaceAcknowledgeable
- Returns:
- a
OnmsNode
object.
-
getNodeId
public java.lang.Integer getNodeId()
-
getNodeLabel
public java.lang.String getNodeLabel()
-
getIpAddr
public java.net.InetAddress getIpAddr()
getIpAddr
- Returns:
- a
String
object.
-
setIpAddr
public void setIpAddr(java.net.InetAddress ipaddr)
setIpAddr
- Parameters:
ipaddr
- aString
object.
-
getServiceType
public OnmsServiceType getServiceType()
getServiceType
- Returns:
- a
OnmsServiceType
object.
-
setServiceType
public void setServiceType(OnmsServiceType service)
setServiceType
- Parameters:
service
- aOnmsServiceType
object.
-
getReductionKey
public java.lang.String getReductionKey()
getReductionKey
- Returns:
- a
String
object.
-
setReductionKey
public void setReductionKey(java.lang.String reductionkey)
setReductionKey
- Parameters:
reductionkey
- aString
object.
-
getAlarmType
public java.lang.Integer getAlarmType()
getAlarmType
- Returns:
- a
Integer
object.
-
setAlarmType
public void setAlarmType(java.lang.Integer alarmtype)
setAlarmType
- Parameters:
alarmtype
- aInteger
object.
-
getCounter
public java.lang.Integer getCounter()
getCounter
- Returns:
- a
Integer
object.
-
setCounter
public void setCounter(java.lang.Integer counter)
setCounter
- Parameters:
counter
- aInteger
object.
-
getSeverityLabel
public java.lang.String getSeverityLabel()
getSeverityLabel
- Returns:
- a
String
object.
-
setSeverityLabel
public void setSeverityLabel(java.lang.String label)
setSeverityLabel
- Parameters:
label
- aString
object.
-
getSeverity
public OnmsSeverity getSeverity()
getSeverity
- Specified by:
getSeverity
in interfaceAcknowledgeable
- Returns:
- a
OnmsSeverity
object.
-
setSeverity
public void setSeverity(OnmsSeverity severity)
setSeverity
- Parameters:
severity
- aOnmsSeverity
object.
-
getSeverityId
public java.lang.Integer getSeverityId()
getSeverityId
- Returns:
- a
Integer
object.
-
setSeverityId
public void setSeverityId(java.lang.Integer severity)
setSeverityId
- Parameters:
severity
- aInteger
object.
-
getFirstEventTime
public java.util.Date getFirstEventTime()
getFirstEventTime
- Returns:
- a
Date
object.
-
setFirstEventTime
public void setFirstEventTime(java.util.Date firsteventtime)
setFirstEventTime
- Parameters:
firsteventtime
- aDate
object.
-
getDescription
public java.lang.String getDescription()
getDescription
- Returns:
- a
String
object.
-
setDescription
public void setDescription(java.lang.String description)
setDescription
- Parameters:
description
- aString
object.
-
getLogMsg
public java.lang.String getLogMsg()
getLogMsg
- Returns:
- a
String
object.
-
setLogMsg
public void setLogMsg(java.lang.String logmsg)
setLogMsg
- Parameters:
logmsg
- aString
object.
-
getOperInstruct
public java.lang.String getOperInstruct()
getOperInstruct
- Returns:
- a
String
object.
-
setOperInstruct
public void setOperInstruct(java.lang.String operinstruct)
setOperInstruct
- Parameters:
operinstruct
- aString
object.
-
getTTicketId
public java.lang.String getTTicketId()
getTTicketId
- Returns:
- a
String
object.
-
setTTicketId
public void setTTicketId(java.lang.String tticketid)
setTTicketId
- Parameters:
tticketid
- aString
object.
-
getTTicketState
public TroubleTicketState getTTicketState()
getTTicketState
- Returns:
- a
TroubleTicketState
object.
-
setTTicketState
public void setTTicketState(TroubleTicketState tticketstate)
setTTicketState
- Parameters:
tticketstate
- aTroubleTicketState
object.
-
getMouseOverText
public java.lang.String getMouseOverText()
getMouseOverText
- Returns:
- a
String
object.
-
setMouseOverText
public void setMouseOverText(java.lang.String mouseovertext)
setMouseOverText
- Parameters:
mouseovertext
- aString
object.
-
getSuppressedUntil
public java.util.Date getSuppressedUntil()
getSuppressedUntil
- Returns:
- a
Date
object.
-
setSuppressedUntil
public void setSuppressedUntil(java.util.Date suppresseduntil)
setSuppressedUntil
- Parameters:
suppresseduntil
- aDate
object.
-
getSuppressedUser
public java.lang.String getSuppressedUser()
getSuppressedUser
- Returns:
- a
String
object.
-
setSuppressedUser
public void setSuppressedUser(java.lang.String suppresseduser)
setSuppressedUser
- Parameters:
suppresseduser
- aString
object.
-
getSuppressedTime
public java.util.Date getSuppressedTime()
getSuppressedTime
- Returns:
- a
Date
object.
-
setSuppressedTime
public void setSuppressedTime(java.util.Date suppressedtime)
setSuppressedTime
- Parameters:
suppressedtime
- aDate
object.
-
getAlarmAckUser
public java.lang.String getAlarmAckUser()
getAlarmAckUser
- Returns:
- a
String
object.
-
setAlarmAckUser
public void setAlarmAckUser(java.lang.String alarmackuser)
setAlarmAckUser
- Parameters:
alarmackuser
- aString
object.
-
isAcknowledged
public boolean isAcknowledged()
-
getAlarmAckTime
public java.util.Date getAlarmAckTime()
getAlarmAckTime
- Returns:
- a
Date
object.
-
setAlarmAckTime
public void setAlarmAckTime(java.util.Date alarmacktime)
setAlarmAckTime
- Parameters:
alarmacktime
- aDate
object.
-
getClearKey
public java.lang.String getClearKey()
getClearKey
- Returns:
- a
String
object.
-
setClearKey
public void setClearKey(java.lang.String clearKey)
setClearKey
- Parameters:
clearKey
- aString
object.
-
setLastEvent
public void setLastEvent(OnmsEvent event)
setLastEvent
- Parameters:
event
- aOnmsEvent
object.
-
getEventParameters
public java.util.List<OnmsEventParameter> getEventParameters()
-
findEventParameter
public java.util.Optional<OnmsEventParameter> findEventParameter(java.lang.String name)
-
getEventParameter
public java.lang.String getEventParameter(java.lang.String name)
-
toString
public java.lang.String toString()
toString
- Overrides:
toString
in classjava.lang.Object
- Returns:
- a
String
object.
-
getLastEventTime
public java.util.Date getLastEventTime()
getLastEventTime
- Returns:
- a
Date
object.
-
setLastEventTime
public void setLastEventTime(java.util.Date lastEventTime)
setLastEventTime
- Parameters:
lastEventTime
- aDate
object.
-
getApplicationDN
public java.lang.String getApplicationDN()
getApplicationDN
- Returns:
- a
String
object.
-
setApplicationDN
public void setApplicationDN(java.lang.String applicationDN)
setApplicationDN
- Parameters:
applicationDN
- aString
object.
-
getManagedObjectInstance
public java.lang.String getManagedObjectInstance()
getManagedObjectInstance
- Returns:
- a
String
object.
-
setManagedObjectInstance
public void setManagedObjectInstance(java.lang.String managedObjectInstance)
setManagedObjectInstance
- Parameters:
managedObjectInstance
- aString
object.
-
getManagedObjectType
public java.lang.String getManagedObjectType()
getManagedObjectType
- Returns:
- a
String
object.
-
setManagedObjectType
public void setManagedObjectType(java.lang.String managedObjectType)
setManagedObjectType
- Parameters:
managedObjectType
- aString
object.
-
getOssPrimaryKey
public java.lang.String getOssPrimaryKey()
getOssPrimaryKey
- Returns:
- a
String
object.
-
setOssPrimaryKey
public void setOssPrimaryKey(java.lang.String key)
setOssPrimaryKey
- Parameters:
key
- aString
object.
-
getX733AlarmType
public java.lang.String getX733AlarmType()
getX733AlarmType
- Returns:
- a
String
object.
-
setX733AlarmType
public void setX733AlarmType(java.lang.String alarmType)
setX733AlarmType
- Parameters:
alarmType
- aString
object.
-
getX733ProbableCause
public int getX733ProbableCause()
getX733ProbableCause
- Returns:
- a int.
-
setX733ProbableCause
public void setX733ProbableCause(int cause)
setX733ProbableCause
- Parameters:
cause
- a int.
-
getQosAlarmState
public java.lang.String getQosAlarmState()
getQosAlarmState
- Returns:
- a
String
object.
-
setQosAlarmState
public void setQosAlarmState(java.lang.String alarmState)
setQosAlarmState
- Parameters:
alarmState
- aString
object.
-
getFirstAutomationTime
public java.util.Date getFirstAutomationTime()
getFirstAutomationTime
- Returns:
- a
Date
object.
-
setFirstAutomationTime
public void setFirstAutomationTime(java.util.Date firstAutomationTime)
setFirstAutomationTime
- Parameters:
firstAutomationTime
- aDate
object.
-
getLastAutomationTime
public java.util.Date getLastAutomationTime()
getLastAutomationTime
- Returns:
- a
Date
object.
-
setLastAutomationTime
public void setLastAutomationTime(java.util.Date lastAutomationTime)
setLastAutomationTime
- Parameters:
lastAutomationTime
- aDate
object.
-
getDetails
public java.util.Map<java.lang.String,java.lang.String> getDetails()
getDetails
- Returns:
- a
Map
object.
-
setDetails
public void setDetails(java.util.Map<java.lang.String,java.lang.String> alarmDetails)
setDetails
- Parameters:
alarmDetails
- aMap
object.
-
getIfIndex
public java.lang.Integer getIfIndex()
getIfIndex
- Returns:
- a
Integer
object.
-
setIfIndex
public void setIfIndex(java.lang.Integer ifIndex)
setIfIndex
- Parameters:
ifIndex
- aInteger
object.
-
getReductionKeyMemo
public OnmsReductionKeyMemo getReductionKeyMemo()
-
setReductionKeyMemo
public void setReductionKeyMemo(OnmsReductionKeyMemo reductionKeyMemo)
-
getStickyMemo
public OnmsMemo getStickyMemo()
-
setStickyMemo
public void setStickyMemo(OnmsMemo stickyMemo)
-
acknowledge
public void acknowledge(java.lang.String user)
acknowledge
- Specified by:
acknowledge
in interfaceAcknowledgeable
- Parameters:
user
- aString
object.
-
unacknowledge
public void unacknowledge(java.lang.String ackUser)
unacknowledge
- Specified by:
unacknowledge
in interfaceAcknowledgeable
- Parameters:
ackUser
- aString
object.
-
clear
public void clear(java.lang.String ackUser)
clear
- Specified by:
clear
in interfaceAcknowledgeable
- Parameters:
ackUser
- aString
object.
-
escalate
public void escalate(java.lang.String ackUser)
escalate
- Specified by:
escalate
in interfaceAcknowledgeable
- Parameters:
ackUser
- aString
object.
-
archive
public void archive()
This marks an alarm as archived and prevents it from being used again in during reduction.
-
isArchived
public boolean isArchived()
-
getType
public AckType getType()
getType
- Specified by:
getType
in interfaceAcknowledgeable
- Returns:
- a
AckType
object.
-
getAckId
public java.lang.Integer getAckId()
getAckId
- Specified by:
getAckId
in interfaceAcknowledgeable
- Returns:
- a
Integer
object.
-
getAckUser
public java.lang.String getAckUser()
getAckUser
- Specified by:
getAckUser
in interfaceAcknowledgeable
- Returns:
- a
String
object.
-
getAckTime
public java.util.Date getAckTime()
getAckTime
- Specified by:
getAckTime
in interfaceAcknowledgeable
- Returns:
- a
Date
object.
-
getRelatedAlarms
public java.util.Set<OnmsAlarm> getRelatedAlarms()
getRelatedAlarms
- Returns:
- a
Set
object.
-
getRelatedAlarmIds
public java.util.Set<java.lang.Integer> getRelatedAlarmIds()
-
getAssociatedAlarms
public java.util.Set<AlarmAssociation> getAssociatedAlarms()
-
setAssociatedAlarms
public void setAssociatedAlarms(java.util.Set<AlarmAssociation> alarms)
-
setRelatedAlarms
public void setRelatedAlarms(java.util.Set<OnmsAlarm> alarms)
-
setRelatedAlarms
public void setRelatedAlarms(java.util.Set<OnmsAlarm> alarms, java.util.Date associationEventTime)
-
addRelatedAlarm
public void addRelatedAlarm(OnmsAlarm alarm)
-
removeRelatedAlarm
public void removeRelatedAlarm(OnmsAlarm alarm)
-
removeRelatedAlarmWithId
public void removeRelatedAlarmWithId(java.lang.Integer relatedAlarmId)
-
isSituation
public boolean isSituation()
-
setSituation
public void setSituation(boolean situation)
-
isPartOfSituation
public boolean isPartOfSituation()
-
setPartOfSituation
public void setPartOfSituation(boolean partOfSituation)
-
getRelatedSituations
public java.util.Set<OnmsAlarm> getRelatedSituations()
-
getRelatedSituationIds
public java.util.Set<java.lang.Integer> getRelatedSituationIds()
-
setRelatedSituations
public void setRelatedSituations(java.util.Set<OnmsAlarm> alarms)
-
getAffectedNodeCount
public java.lang.Integer getAffectedNodeCount()
-
getLastUpdateTime
public java.util.Date getLastUpdateTime()
-
-