|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.tivoli.twg.monitor.TWGMonThresholdEvent
This is the TWGMonThresholdEvent class. This class is used to transport data for monitor events to the monitor server. Events described by this class are delivered to the TWGMonThresholdEventSink object that the subsystem has access to
TWGMonThresholdEventSink
Field Summary | |
---|---|
static int |
CURRENT_THRESHOLD_EVENT_VERSION
|
static int |
V12GA_THRESHOLD_EVENT_VERSION
|
Constructor Summary | |
---|---|
TWGMonThresholdEvent()
This is the constructor for building an event to be sent from the subsystem to the Event Sink object in the monitor server. |
Method Summary | |
---|---|
double |
getActualValue()
|
short |
getAlertSeverity()
It uses the alert severities as defined by the EVENT_SEVERITY_xxx constants in the Alert Manager class: TWGBaseEvent. |
byte |
getAlertType()
returns a bit mask indicating the type of alert that this object is reflecting. |
byte |
getDataType()
gets a flag byte that indicates via set bits the type of data being returned with the event |
int |
getDuration()
returns a value indicating the number of seconds that we were in the state |
int |
getEventTime()
returns the time in secs when the event was generated on the Agent |
long |
getEventTimeMSecs()
returns the time in msecs when the event was generated on the Agent |
long |
getManagedObjID()
returns the managed object id of the system that is the source of the event |
long |
getThreshCTAD()
gets the creation time and data portion of the threshold id object contained herein |
int |
getThreshID()
gets the id portion of the TWGMonThresholdId object contained in this object |
TWGMonThresholdId |
getThreshIDClass()
gets the threshold id object that describes what threshold is popping |
int |
getTime()
returns the time that the system first detected the state being reflected in the event |
java.lang.String |
getValueString()
returns a string for events from string based attributes |
boolean |
isChangedEvent()
Gets whether this event is a change event |
boolean |
isQueuedEvent()
Gets whether this event was queued on the agent before is could be sent |
boolean |
isValid()
Gets whether this object contains valid data |
void |
setActualValue(double parm)
sets the numeric value for an event from a numeric attribute type |
void |
setAlertType(byte parm)
sets the alert type that the event is reflecting to the server The possible settings for the alert Type byte are: numeric attributes: TWGMonThreshold.HIGH_ERROR_THRESHOLD Indicates the measured value is above the High Error set point TWGMonThreshold.LOW_ERROR_THRESHOLD Indicates the measured value is below the Low Error set point TWGMonThreshold.HIGH_WARNING_THRESHOLD Indicates that the measured value is above the High Warning set point and below the High Error setting, if set. |
void |
setDataType(byte parm)
sets the flag that indicates the type of data the event contains |
void |
setDuration(int parm)
sets the duration in seconds that the condition has existed |
void |
setEventTime(int parm)
sets the time when the event was generated on the Agent |
void |
setManagedObjID(long parm)
sets the managed object id that represents the source of this event |
void |
setThreshIDandCTAD(int id,
long ctad)
creates and sets the threshold id object with the information describing the threshold that occurred |
void |
setTime(int parm)
sets the time condition started to occur |
void |
setValid(boolean parm)
Method to set flag that indicates if the state of the object is valid. |
void |
setValueString(java.lang.String parm)
set the data value for string attribute threshold events |
java.lang.String |
toString()
Returns string'ed version of instance. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int V12GA_THRESHOLD_EVENT_VERSION
public static final int CURRENT_THRESHOLD_EVENT_VERSION
Constructor Detail |
public TWGMonThresholdEvent()
Method Detail |
public void setValid(boolean parm)
parm
- flag indicating if the object's state should
be considered validpublic void setThreshIDandCTAD(int id, long ctad)
id
- unique id of the thresholdctad
- creation time and date in secondspublic void setDataType(byte parm)
parm
- data type of the data being reported with the eventpublic void setAlertType(byte parm)
parm
- alert type of this eventpublic void setManagedObjID(long parm)
parm
- managed object id of the sourcepublic void setActualValue(double parm)
parm
- value that the attribute is reporting as the cause of the eventpublic void setTime(int parm)
parm
- time the condition started to occurpublic void setEventTime(int parm)
parm
- UTC time in secs when the event was createdpublic void setDuration(int parm)
parm
- time in seconds the condition existedpublic void setValueString(java.lang.String parm)
parm
- string object with the value causing the event for string attributespublic TWGMonThresholdId getThreshIDClass()
public int getThreshID()
public long getThreshCTAD()
public byte getDataType()
public byte getAlertType()
public long getManagedObjID()
public double getActualValue()
public int getTime()
public int getEventTime()
public long getEventTimeMSecs()
public int getDuration()
public java.lang.String getValueString()
public boolean isValid()
public boolean isQueuedEvent()
public boolean isChangedEvent()
public java.lang.String toString()
public short getAlertSeverity()
This method maps the alert that is being reported to a Director event severity level. The mapping is that all 'error' items are mapped to EVENT_SEVERITY_CRITICAL, all 'warning' items are mapped to EVENT_SEVERITY_WARNING and all 'normal' items are mapped to EVENT_SEVERITY_HARMLESS. This is done by first checking for error alerts then looking for warning and normal alerts. if none of those alert bits are set, then the severity level of EVENT_SEVERITY_UNKNOWN is returned.
This method is used by the monitor server when processing a threshold event and preparing to send it to the alert manager.
TWGPartialEvent.EVENT_SEVERITY_WARNING
,
TWGPartialEvent.EVENT_SEVERITY_CRITICAL
,
TWGPartialEvent.EVENT_SEVERITY_HARMLESS
,
TWGPartialEvent.EVENT_SEVERITY_UNKNOWN
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |