|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
RASIEvent defines the methods that must be implemented
to contain RAS message or trace data.
Within the RAS Toolkit, RASIEvent is implemented by
the RASEvent
class.
Method Summary | |
---|---|
java.lang.Object |
getAttribute(java.lang.String name)
Gets an attribute that is saved as part of a RAS event. |
java.lang.String[] |
getParameters()
Gets the text parameters: Strings to be displayed with the message text. |
java.util.Hashtable |
getSupportedTypes()
Gets the complete set of event types supported by this class. |
java.lang.String |
getText()
Gets the event text. |
long |
getTimeStamp()
Gets the time at which this event was created. |
long |
getType()
Gets the type of event: "informational message," for example. |
boolean |
isMessageEvent()
Determines if this object is a message event or a trace event. |
long |
maskLongValue(java.lang.String types)
Converts a String representation of a message or trace mask to its long equivalent. |
java.lang.String |
maskToString(long types)
Converts a long containing the logical OR of one or more event types to its String equivalent. |
void |
setAttribute(java.lang.String name,
java.lang.Object attrib)
Sets an attribute, saving it as part of a RAS event. |
void |
setMessageEvent(boolean flag)
Sets a flag that that indicates whether this object is classified as a message event or a trace event. |
void |
setParameters(java.lang.String[] parms)
Gets the text parameters: Strings to be displayed with the message text. |
void |
setText(java.lang.String text)
Sets the event text. |
void |
setTimeStamp(long timeStamp)
Sets the time at which this event was created. |
void |
setType(long type)
Sets the type of event: "informational message," for example. |
Method Detail |
public long getTimeStamp()
timeStamp
- The event time stamp, as generated by
System.currentTimeMillis.public void setTimeStamp(long timeStamp)
timeStamp
- The event time stamp.public long getType()
RASEvent
.public void setType(long type)
RASEvent
.type
- The event type.public java.lang.String getText()
public void setText(java.lang.String text)
text
- The event text.public java.lang.String[] getParameters()
public void setParameters(java.lang.String[] parms)
parms
- The text parameters.public java.lang.Object getAttribute(java.lang.String name)
name
- The name of the attribute.public void setAttribute(java.lang.String name, java.lang.Object attrib)
name
- The name of the attribute.attrib
- The attribute associated with the name.public void setMessageEvent(boolean flag)
flag
- true if this object is a message event and
false if it is a trace event.public boolean isMessageEvent()
public java.util.Hashtable getSupportedTypes()
This method can be used by a graphical log manager to display the set of types and allow a user to select those to be monitored. Every extending class should override this method to add the types it supports to the Hashtable returned by its parent.
Hashtable
requirement that all elements be Objects.public long maskLongValue(java.lang.String types)
String types = "TYPE_INFO TYPE_WARN";Unknown values in the String are ignored.
types
- The blank-delimited String to be converted.String
, formed by
the logical OR of each element in the String.public java.lang.String maskToString(long types)
String types = "TYPE_INFO TYPE_WARN";Every extending class should override this method to add the types it supports to the value returned by its parent.
Unknown values in the long are ignored.
types
- The message or trace mask.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |