Class Alarm


  • public class Alarm
    extends Object
    Alarm
    • Constructor Detail

      • Alarm

        public Alarm​(org.netxms.base.NXCPMessage msg)
        Parameters:
        msg - Source NXCP message
    • Method Detail

      • setResolved

        public void setResolved​(int userId,
                                Date changeTime)
        Mark alarm as resolved. This call only updates local object state and do not change actual alarm state on server. It can be used to update local alarm objects after receiving bulk alarm state change notification.
        Parameters:
        userId -
        changeTime -
      • getId

        public long getId()
        Returns:
        the id
      • getParentId

        public long getParentId()
        Returns:
        the parentId
      • getCurrentSeverity

        public Severity getCurrentSeverity()
        Returns:
        the currentSeverity
      • getOriginalSeverity

        public Severity getOriginalSeverity()
        Returns:
        the originalSeverity
      • getRepeatCount

        public int getRepeatCount()
        Returns:
        the repeatCount
      • getState

        public int getState()
        Returns:
        the state
      • getAcknowledgedByUser

        public int getAcknowledgedByUser()
        Get id of user that acknowledged this alarm (or 0 if alarm is not acknowledged).
        Returns:
        id of user that acknowledged this alarm (or 0 if alarm is not acknowledged)
      • getTerminatedByUser

        public int getTerminatedByUser()
        Get id of user that terminated this alarm (or 0 if alarm is not terminated).
        Returns:
        id of user that terminated this alarm (or 0 if alarm is not terminated)
      • getSourceEventId

        public long getSourceEventId()
        Returns:
        the sourceEventId
      • getSourceEventCode

        public int getSourceEventCode()
        Returns:
        the sourceEventCode
      • getSourceObjectId

        public long getSourceObjectId()
        Returns:
        the sourceObjectId
      • getDciId

        public long getDciId()
        Returns:
        the dciId
      • getCreationTime

        public Date getCreationTime()
        Returns:
        the creationTime
      • getLastChangeTime

        public Date getLastChangeTime()
        Returns:
        the lastChangeTime
      • getMessage

        public String getMessage()
        Returns:
        the message
      • getKey

        public String getKey()
        Returns:
        the key
      • getHelpdeskState

        public int getHelpdeskState()
        Returns:
        the helpdeskState
      • getHelpdeskReference

        public String getHelpdeskReference()
        Returns:
        the helpdeskReference
      • getTimeout

        public int getTimeout()
        Returns:
        the timeout
      • getTimeoutEvent

        public int getTimeoutEvent()
        Returns:
        the timeoutEvent
      • getCommentsCount

        public int getCommentsCount()
        Returns:
        the commentsCount
      • getResolvedByUser

        public int getResolvedByUser()
        Get id of user that resolved this alarm (or 0 if alarm is not resolved).
        Returns:
        id of user that resolved this alarm (or 0 if alarm is not resolved)
      • isSticky

        public boolean isSticky()
        Returns:
        the sticky
      • getAckTime

        public int getAckTime()
        Get time when alarm was acknowledged
        Returns:
        time when alarm was acknowledged
      • getCategories

        public long[] getCategories()
        Get list of categories this alarm belongs to.
        Returns:
        list of categories this alarm belongs to
      • getSubordinateAlarms

        public long[] getSubordinateAlarms()
        Get list of subordinate alarm identifiers.
        Returns:
        list of subordinate alarm identifiers
      • hasSubordinatedAlarms

        public boolean hasSubordinatedAlarms()
        Check if this alarm has any subordinated alarms.
        Returns:
        true if this alarm has any subordinated alarms