|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.ras.RASEvent | +--com.ibm.ras.RASMessageEvent
RASMessageEvent encapsulates all of the information generated
by a RASMessageLogger
. It is not necessary
to create a RASMessageEvent directly, as the message logger
handles this task. However, the methods of this class are public, should
it be necessary to extend RASMessageEvent.
A RASMessageEvent contains the following components:
Strings
.
Constants for these attributes are defined in the RASConstants
class.
The RASMessageEvent type is defined by the set of
RASIMessageEvent
TYPE_XXXX constants.
Values 0x0000L up to, but not including, 0x01000L are reserved.
Extensions to the RASMessageEvent class may use values outside
this range for additional types. The constant
RASIMessageEvent.DEFAULT_MESSAGE_MASK
contains the message types that the handlers log by default. It includes all
message types.
RASEvent
, Serialized FormFields inherited from interface com.ibm.ras.RASIMessageEvent |
---|
ALL_MESSAGE_MASK, DEFAULT_MESSAGE_MASK, TYPE_ERR, TYPE_ERROR, TYPE_INFO, TYPE_INFORMATION, TYPE_WARN, TYPE_WARNING |
Constructor Summary | |
---|---|
|
RASMessageEvent()
Creates a RASMessageEvent. |
protected |
RASMessageEvent(long type,
java.lang.String text,
java.lang.Object[] parms,
java.lang.String messageFile)
Creates a RASMessageEvent. |
|
RASMessageEvent(long type,
java.lang.String text,
java.lang.Object[] parms,
java.lang.String messageFile,
java.lang.String loggingClass,
java.lang.String loggingMethod,
java.lang.String org,
java.lang.String prod,
java.lang.String comp,
java.lang.String server,
java.lang.String client,
java.lang.Throwable exception)
Creates a RASMessageEvent. |
protected |
RASMessageEvent(long type,
java.lang.String text,
java.lang.String[] parms,
java.lang.String messageFile)
Deprecated. Use RASMessageEvent instead. |
|
RASMessageEvent(long type,
java.lang.String text,
java.lang.String[] parms,
java.lang.String messageFile,
java.lang.String loggingClass,
java.lang.String loggingMethod,
java.lang.String org,
java.lang.String prod,
java.lang.String comp,
java.lang.String server,
java.lang.String client,
java.lang.Throwable exception)
Deprecated. Use RASMessageEvent instead. |
Method Summary | |
---|---|
java.lang.String |
getMessageFile()
Gets the base message file name used to format a message. |
java.util.Hashtable |
getSupportedTypes()
Gets the complete set of event types supported by this class. |
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 |
setMessageFile(java.lang.String messageFile)
Sets the base message file name used to format a message. |
java.lang.String |
toString()
Returns a String representation of this object. |
Methods inherited from class com.ibm.ras.RASEvent |
---|
getAttribute, getParameters, getText, getTimeStamp, getType, isMessageEvent, objectsToStrings, setAttribute, setMessageEvent, setParameters, setText, setTimeStamp, setType |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public RASMessageEvent()
protected RASMessageEvent(long type, java.lang.String text, java.lang.Object[] parms, java.lang.String messageFile)
type
- The message type.text
- The message text, or a message key if the message file
is not null.parms
- An array of Objects
to be displayed
with the message.messageFile
- The base message file name.protected RASMessageEvent(long type, java.lang.String text, java.lang.String[] parms, java.lang.String messageFile)
RASMessageEvent
instead.
type
- The message type.text
- The message text, or a message key if the message file
is not null.parms
- An array of Strings
to be displayed
with the message.messageFile
- The base message file name.public RASMessageEvent(long type, java.lang.String text, java.lang.Object[] parms, java.lang.String messageFile, java.lang.String loggingClass, java.lang.String loggingMethod, java.lang.String org, java.lang.String prod, java.lang.String comp, java.lang.String server, java.lang.String client, java.lang.Throwable exception)
type
- The message type.text
- The message text, or a message key if the message file
is not null.parms
- An array of Objects
to be displayed
with the message.messageFile
- The base message file name.loggingClass
- The class.loggingMethod
- The method.org
- The organization.prod
- The product.comp
- The component.server
- The server.client
- The client.exception
- A Throwable object.public RASMessageEvent(long type, java.lang.String text, java.lang.String[] parms, java.lang.String messageFile, java.lang.String loggingClass, java.lang.String loggingMethod, java.lang.String org, java.lang.String prod, java.lang.String comp, java.lang.String server, java.lang.String client, java.lang.Throwable exception)
RASMessageEvent
instead.
type
- The message type.text
- The message text, or a message key if the message file
is not null.parms
- An array of Strings
to be displayed
with the message.messageFile
- The base message file name.loggingClass
- The class.loggingMethod
- The method.org
- The organization.prod
- The product.comp
- The component.server
- The server.client
- The client.exception
- A Throwable object.Method Detail |
public java.lang.String getMessageFile()
public void setMessageFile(java.lang.String messageFile)
messageFile
- The message file name.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.
getSupportedTypes
in class RASEvent
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.
maskLongValue
in class RASEvent
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.
maskToString
in class RASEvent
types
- The message or trace mask.public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |