Class RASMessageLogger
- java.lang.Object
-
- com.ibm.ras.RASObject
-
- com.ibm.ras.RASMaskChangeGenerator
-
- com.ibm.ras.RASLogger
-
- com.ibm.ras.RASMessageLogger
-
- All Implemented Interfaces:
- RASConstants, RASILogger, RASIMaskChangeGenerator, RASIMaskChangeListener, RASIMessageEvent, RASIMessageLogger, RASIObject, java.io.Serializable, java.lang.Cloneable, java.util.EventListener
- Direct Known Subclasses:
- WsJrasMessageLogger
Deprecated.As of WAS 6.0, recommend using java.util.logging
public class RASMessageLogger extends RASLogger implements RASIMessageLogger, RASIMessageEvent
RASMessageLoggergenerates message data and is one of twoRASLoggersub-classes provided in this package. (The other isRASTraceLogger.) The purpose of message logging is to provide information to the users of an application. (Contrast this with tracing, which is intended for software developers and service teams.) As a general guideline, a message should be logged only if the information it contains is of value to the user.By default, message logging is on when a
RASMessageLoggeris created.RASMessageLoggersupports three types of messages: information, warning and error. For warning and error messages, you should provide details telling the customer how to rectify the situation. These types are formally defined in theRASIMessageEventclass. Themessage,msgandtextMessagemethods do not validate the type assigned to a message, so an error could result in the failure to log the message.Normally, the text for a set of messages is stored in one or more message files. Text strings are accessed by a "key," which is a name for the message text. This mechanism allows the message text to be separated from the program that uses it, making translation into different languages easier.
A message logger, therefore, must be told which message files to search. Two mechanisms are available to accomplish this:
- When the message is logged, name the message file containing the
message key. The
msgmethods in this class do this. - Use
setMessageFileto register one message file with the message logger. Themessagemethods in this class assume that one message file has been registered. If more than one message file is required, themsgmethods can be used with the additional message files.
The message key can be any desired string. For example, a key
HUNGRYmight select the message text, "Are you ready to eat?" This key may be displayed as part of a formatted message and can be used more formally to identify messages. For example, instead ofHUNGRY, the key might beRAS0001I. In this scheme the first three characters identify the product or, perhaps, component -- the RAS Toolkit, in this case. The next four numbers select a RAS message. The last character is set toIfor informational messages,Wfor warning messages andEfor error messages.If a message file is not specified, or the message key is not found in the message file, an error message is formatted instead.
The message files may be any subclass of
java.util.ResourceBundles. In practice, thePropertyResourceBundleis usually the most practical form to use. Within the RAS Toolkit, theseResourceBundlesare wrapped by theRASMessageCatalogclass, which provides methods to conveniently format the message strings. SeesetMessageFilefor information on how to specify the message file name.Run-time substitution of variables into the message text is possible. The
message,msgandtextMessagemethods accept a number ofObjectswhoseStringrepresentations may be inserted into the message text according to the rules of thejava.text.MessageFormatclass. The only restriction is that theObjectsare converted toStringsbefore they are passed to the MessageFormat class, so that the MessageFormat style options (such as{1,time}) may not be used.RASMessageLoggerprovides the ability to suppress individual messages. This feature might be used if a program were logging the same message again and again and the system administrator did not want to see any more of them. TheaddSuppressedKeymethod is used to stop the logging of specific messages.The
messageandmsgmethods all include the name of the class and method which generated the message. When logging messages in non-static methods, you may use the methods that take "this" (the object being traced) as the second parameter. This is a convenience to the programmer, as the class name can be derived from anyObject. For static methods, an object does not exist. Use the methods which take "String className" as the second parameter. This latter approach may be used in all methods, if desired. It will also result in better performance (significant if many messages are logged), as the RAS system will not have to translate anObjectto a class name.RASMessageLoggerprovides minimal support for the logging of plain text messages which do not use message catalogs. ThetextMessagemethods are available for this. They are provided as a convenience for an application developer who might want to log a quick debug message that will not make it into the final product. ThetextMessagemethod takes an arbitrary text string in place of a message key.Objectsmay be included with the message, but they are displayed with the message text (according to theirtoStringrepresentation), not substituted into the message text.RASMessageLoggerhas several optional fields which may be included in the message. These fields should not vary among messages produced by a givenRASMessageLogger, so they are not included in themessagemethods of this class. They can, however, be specified through aRASMessageLoggerconstructor or by the appropriate "set" and "get" methods of this class. These fields are:- The name of the organization which owns the application that creates these messages.
- The name of the product that creates these messages.
- The name of the component within the product that creates these messages.
- A server associated with the creation of the messages.
- The client on whose behalf the messages are created.
Note: Classes which extend
RASMessageLoggershould, in their constructors, calladdMessageEventClassto register theRASIEventclasses which the logger generates. This will allow a graphical program to query the logger to determine the supported RAS events. The events, in turn, can be queried to determine their set of supported event types.- See Also:
RASIMessageLogger,RASMessageEvent,RASIHandler, Serialized Form
-
-
Field Summary
-
Fields inherited from class com.ibm.ras.RASLogger
handlerFailures, isLoggableMask, isLogging
-
Fields 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
-
Fields inherited from interface com.ibm.ras.RASConstants
KEY_CLASS_NAME, KEY_CLIENT, KEY_COMPONENT, KEY_DATE_FORMAT, KEY_DEFAULT_HANDLERS, KEY_DEFAULT_MESSAGE_HANDLERS, KEY_DEFAULT_TRACE_HANDLERS, KEY_DESCRIPTION, KEY_ENCODING, KEY_EXCEPTION, KEY_EXCEPTION_TRACE, KEY_FILE_NAME, KEY_FORMATTER_NAMES, KEY_GROUP, KEY_HANDLER_NAMES, KEY_HEX_DATA, KEY_IS_CIRCULAR, KEY_IS_LOGGING, KEY_IS_SYNC, KEY_LOGGER, KEY_LOGGING_CLASS, KEY_LOGGING_METHOD, KEY_MAX_FILE_SIZE, KEY_MAX_FILES, KEY_MAX_QUEUE_SIZE, KEY_MESSAGE_EVENT_CLASSES, KEY_MESSAGE_FILE, KEY_MESSAGE_MASK, KEY_NAME, KEY_ORGANIZATION, KEY_PRODUCT, KEY_RETRY_INTERVAL, KEY_SEPARATOR, KEY_SERVER, KEY_SOCKET_PORT, KEY_SOCKET_SERVER, KEY_SUPPRESSED_KEYS, KEY_THREAD_ID, KEY_TIME_FORMAT, KEY_TRACE_EVENT_CLASSES, KEY_TRACE_MASK, RAS_VERSION
-
-
Constructor Summary
Constructors Constructor and Description RASMessageLogger()Deprecated.Creates aRASMessageLogger.RASMessageLogger(java.lang.String name)Deprecated.Creates aRASMessageLogger.RASMessageLogger(java.lang.String name, java.lang.String desc)Deprecated.Creates aRASMessageLogger.RASMessageLogger(java.lang.String name, java.lang.String desc, java.lang.String org, java.lang.String prod, java.lang.String comp, java.lang.String server, java.lang.String client)Deprecated.Creates aRASMessageLogger.
-
Method Summary
Methods Modifier and Type Method and Description voidaddSuppressedKey(java.lang.String key)Deprecated.Adds a single message key to a set of keys which should not be logged.voidexception(long type, java.lang.Object obj, java.lang.String methodName, java.lang.Exception exception)Deprecated.Logs anExceptionin a non-static method.voidexception(long type, java.lang.Object obj, java.lang.String methodName, java.lang.Throwable exception)Deprecated.Logs anExceptionin a non-static method.voidexception(long type, java.lang.String className, java.lang.String methodName, java.lang.Exception exception)Deprecated.Logs anExceptionin a static method.voidexception(long type, java.lang.String className, java.lang.String methodName, java.lang.Throwable exception)Deprecated.Logs anExceptionin a static method.java.lang.StringgetComponent()Deprecated.Gets the name of the component that is using this logger.java.util.HashtablegetConfig()Deprecated.Gets the configuration of this object.java.lang.StringgetMessageFile()Deprecated.Gets the message file associated with this logger.java.lang.StringgetOrganization()Deprecated.Gets the name of the organization which wrote the application that is using this logger.java.lang.StringgetProduct()Deprecated.Gets the name of the product that is using this logger.java.util.VectorgetSuppressedKeys()Deprecated.Gets all of the suppressed message keys associated with this logger.protected voidinit()Deprecated.Initializes this object, setting default values.protected voidlogMsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String keyOrText, java.lang.String file, java.lang.Object[] parms, java.lang.Throwable exception)Deprecated.Generates aRASMessageEventand sends it to all attached handlers.voidmaskValueChanged(RASMaskChangeEvent mc)Deprecated.Indicates that the value of the handler's message mask has changed.voidmessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key)Deprecated.Logs a message, by key, with no parameters.voidmessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object parm1)Deprecated.Logs a message, by key, with one parameter.voidmessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object[] parms)Deprecated.Logs a message, by key, with an array of parameters.voidmessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key, with two parameters.voidmessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String key)Deprecated.Logs a message, by key, with no parameters.voidmessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object parm1)Deprecated.Logs a message, by key, with one parameter.voidmessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object[] parms)Deprecated.Logs a message, by key, with an array of parameters.voidmessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key, with two parameters.voidmsg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file)Deprecated.Logs a message, by key and file, with no parameters.voidmsg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1)Deprecated.Logs a message, by key and file, with one parameter.voidmsg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object[] parms)Deprecated.Logs a message, by key and file, with an array of parameters.voidmsg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key and file, with two parameters.voidmsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file)Deprecated.Logs a message, by key and file, with no parameters.voidmsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1)Deprecated.Logs a message, by key and file, with one parameter.voidmsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object[] parms)Deprecated.Logs a message, by key and file, with an array of parameters.voidmsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key and file, with two parameters.voidremoveSuppressedKey(java.lang.String key)Deprecated.Removes a single message key from the set of keys which should not be logged.voidsetComponent(java.lang.String name)Deprecated.Sets the name of the component that is using this logger.voidsetConfig(java.util.Hashtable ht)Deprecated.Sets the configuration of this object.voidsetMessageFile(java.lang.String file)Deprecated.Sets the message file associated with this logger.voidsetOrganization(java.lang.String name)Deprecated.Sets the name of the organization which wrote the application that is using this logger.voidsetProduct(java.lang.String name)Deprecated.Sets the name of the product that is using this logger.voidtextMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text)Deprecated.Logs a text message (no key) with no parameters.voidtextMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object parm1)Deprecated.Logs a text message (no key) with one parameter.voidtextMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object[] parms)Deprecated.Logs a text message (no key) with an array of parameters.voidtextMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a text message (no key) with two parameters.voidtextMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text)Deprecated.Logs a text message (no key) with no parameters.voidtextMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object parm1)Deprecated.Logs a text message (no key) with one parameter.voidtextMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object[] parms)Deprecated.Logs a text message (no key) with an array of parameters.voidtextMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a text message (no key) with two parameters.-
Methods inherited from class com.ibm.ras.RASLogger
addHandler, fireRASEvent, getClient, getHandlers, getServer, isLoggable, isLogging, isSynchronous, removeHandler, setClient, setLogging, setServer, setSynchronous
-
Methods inherited from class com.ibm.ras.RASMaskChangeGenerator
addMaskChangeListener, addMessageEventClass, addTraceEventClass, fireMaskChangedEvent, getMaskChangeListeners, getMessageEventClasses, getMessageMask, getTraceEventClasses, getTraceMask, messageMaskLongValue, messageMaskToString, removeMaskChangeListener, removeMessageEventClass, removeTraceEventClass, setMessageMask, setTraceMask, traceMaskLongValue, traceMaskToString
-
Methods inherited from class com.ibm.ras.RASObject
clone, getDescription, getGroup, getName, setDescription, setName
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ibm.ras.RASIMessageLogger
getMessageMask, setMessageMask
-
Methods inherited from interface com.ibm.ras.RASILogger
addHandler, fireRASEvent, getClient, getHandlers, getServer, isLoggable, isLogging, isSynchronous, removeHandler, setClient, setLogging, setServer, setSynchronous
-
Methods inherited from interface com.ibm.ras.RASIMaskChangeGenerator
addMaskChangeListener, addMessageEventClass, addTraceEventClass, fireMaskChangedEvent, getMaskChangeListeners, getMessageEventClasses, getTraceEventClasses, getTraceMask, removeMaskChangeListener, removeMessageEventClass, removeTraceEventClass, setTraceMask
-
Methods inherited from interface com.ibm.ras.RASIObject
getDescription, getGroup, getName, setDescription, setName
-
-
-
-
Constructor Detail
-
RASMessageLogger
public RASMessageLogger()
Deprecated.Creates aRASMessageLogger. The name and description of this object are empty strings.
-
RASMessageLogger
public RASMessageLogger(java.lang.String name)
Deprecated.Creates aRASMessageLogger. The description of this object is an empty string.- Parameters:
name- The name of this object.
-
RASMessageLogger
public RASMessageLogger(java.lang.String name, java.lang.String desc)Deprecated.Creates aRASMessageLogger.- Parameters:
name- The name of this object.desc- The description of this object.
-
RASMessageLogger
public RASMessageLogger(java.lang.String name, java.lang.String desc, java.lang.String org, java.lang.String prod, java.lang.String comp, java.lang.String server, java.lang.String client)Deprecated.Creates aRASMessageLogger. (See the prologue for a description of each of these elements.)- Parameters:
name- The name of this logger.desc- The description of this logger.org- The organization.prod- The product.comp- The component.server- The server.client- The client.
-
-
Method Detail
-
init
protected void init()
Deprecated.Initializes this object, setting default values.
-
getConfig
public java.util.Hashtable getConfig()
Deprecated.Gets the configuration of this object.- Specified by:
getConfigin interfaceRASILogger- Specified by:
getConfigin interfaceRASIMaskChangeGenerator- Specified by:
getConfigin interfaceRASIMessageLogger- Specified by:
getConfigin interfaceRASIObject- Overrides:
getConfigin classRASLogger- Returns:
- A
Hashtablecontaining the configuration. This object inserts the following key/value pairs into the configuration:- organization
- The organization.
- product
- The product.
- component
- The component.
- messageFile
- A message file name, used to translate message keys.
- suppressedKeys
- A blank-delimited set of message keys which are not to be processed.
All values are
Strings. The parent and extensions of this object may add additional keys.
-
setConfig
public void setConfig(java.util.Hashtable ht)
Deprecated.Sets the configuration of this object. This method is used by aRASManagerto initialize a RAS object. It should not be necessary for an application to use this method.- Specified by:
setConfigin interfaceRASILogger- Specified by:
setConfigin interfaceRASIMaskChangeGenerator- Specified by:
setConfigin interfaceRASIMessageLogger- Specified by:
setConfigin interfaceRASIObject- Overrides:
setConfigin classRASLogger- Parameters:
ht- AHashtablecontaining the configuration. This object searches for the following keys:- organization
- The organization.
- product
- The product.
- component
- The component.
- messageFile
- A message file name, used to translate message keys.
- suppressedKeys
- A blank-delimited set of message keys which are not to be processed.
All values are
Strings. If a key is not found, an internal default for that element is set instead. The parent and extensions of this object may use additional keys.
-
getOrganization
public java.lang.String getOrganization()
Deprecated.Gets the name of the organization which wrote the application that is using this logger.- Specified by:
getOrganizationin interfaceRASIMessageLogger- Returns:
- The organization name, or an empty string ("") if the organization has not been set.
-
setOrganization
public void setOrganization(java.lang.String name)
Deprecated.Sets the name of the organization which wrote the application that is using this logger. If the name isnull, the current name is not changed.- Specified by:
setOrganizationin interfaceRASIMessageLogger- Parameters:
name- The organization name.
-
getProduct
public java.lang.String getProduct()
Deprecated.Gets the name of the product that is using this logger.- Specified by:
getProductin interfaceRASIMessageLogger- Returns:
- The product name, or an empty string ("") if the product has not been set.
-
setProduct
public void setProduct(java.lang.String name)
Deprecated.Sets the name of the product that is using this logger. If the name isnull, the current name is not changed.- Specified by:
setProductin interfaceRASIMessageLogger- Parameters:
name- The product name.
-
getComponent
public java.lang.String getComponent()
Deprecated.Gets the name of the component that is using this logger.- Specified by:
getComponentin interfaceRASIMessageLogger- Returns:
- The component name, or an empty string ("") if the component has not been set.
-
setComponent
public void setComponent(java.lang.String name)
Deprecated.Sets the name of the component that is using this logger. If the name isnull, the current name is not changed.- Specified by:
setComponentin interfaceRASIMessageLogger- Parameters:
name- The component name.
-
getMessageFile
public java.lang.String getMessageFile()
Deprecated.Gets the message file associated with this logger.- Specified by:
getMessageFilein interfaceRASIMessageLogger- Returns:
- The message file name, or
nullif a message file has not been added to the logger.
-
setMessageFile
public void setMessageFile(java.lang.String file)
Deprecated.Sets the message file associated with this logger. If the file isnull, the current message file is not changed. If the message file does not exist, a message indicating this will be displayed in place of the formatted message.The message file name is the base name of the
java.util.ResourceBundlecontaining the messages. For example, if your base file wascom.ibm.ras.RASMsgs.propertiesyou would pass "com.ibm.ras.RASMsgs" to this method.- Specified by:
setMessageFilein interfaceRASIMessageLogger- Parameters:
file- The message file name.
-
addSuppressedKey
public void addSuppressedKey(java.lang.String key)
Deprecated.Adds a single message key to a set of keys which should not be logged. More than one message key may be in this set. If the key isnullor is already registered, this method does nothing.- Specified by:
addSuppressedKeyin interfaceRASIMessageLogger- Parameters:
key- The message key which is not to be logged.
-
removeSuppressedKey
public void removeSuppressedKey(java.lang.String key)
Deprecated.Removes a single message key from the set of keys which should not be logged. If the key isnullor is not registered, this method does nothing.- Specified by:
removeSuppressedKeyin interfaceRASIMessageLogger- Parameters:
key- The message key to be removed.
-
getSuppressedKeys
public java.util.Vector getSuppressedKeys()
Deprecated.Gets all of the suppressed message keys associated with this logger.- Specified by:
getSuppressedKeysin interfaceRASIMessageLogger- Returns:
- A
Vectorof message keys. If no suppressed keys are registered, theVectoris empty.
-
message
public void message(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key)Deprecated.Logs a message, by key, with no parameters. This call can be used in a non-static method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.
-
message
public void message(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object parm1)Deprecated.Logs a message, by key, with one parameter. This call can be used in a non-static method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.parm1- An element to be inserted into the message.
-
message
public void message(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key, with two parameters. This call can be used in a non-static method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.parm1- An element to be inserted into the message.parm2- An element to be inserted into the message.
-
message
public void message(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.Object[] parms)Deprecated.Logs a message, by key, with an array of parameters. This call can be used in a non-static method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.parms- An array of elements to be inserted into the message.
-
message
public void message(long type, java.lang.String className, java.lang.String methodName, java.lang.String key)Deprecated.Logs a message, by key, with no parameters. This call can be used in any method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.
-
message
public void message(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object parm1)Deprecated.Logs a message, by key, with one parameter. This call can be used in any method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.parm1- An element to be inserted into the message.
-
message
public void message(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key, with two parameters. This call can be used in any method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.parm1- An element to be inserted into the message.parm2- An element to be inserted into the message.
-
message
public void message(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.Object[] parms)Deprecated.Logs a message, by key, with an array of parameters. This call can be used in any method and assumes that at least one message file is registered with the logger.- Specified by:
messagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.parms- An array of elements to be inserted into the message.
-
msg
public void msg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file)Deprecated.Logs a message, by key and file, with no parameters. This call can be used in a non-static method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.file- The name of the message file to use.
-
msg
public void msg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1)Deprecated.Logs a message, by key and file, with one parameter. This call can be used in a non-static method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parm1- An element to be inserted into the message.
-
msg
public void msg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key and file, with two parameters. This call can be used in a non-static method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parm1- An element to be inserted into the message.parm2- An element to be inserted into the message.
-
msg
public void msg(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object[] parms)Deprecated.Logs a message, by key and file, with an array of parameters. This call can be used in a non-static method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parms- An array of elements to be inserted into the message.
-
msg
public void msg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file)Deprecated.Logs a message, by key and file, with no parameters. This call can be used in any method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.file- The name of the message file to use.
-
msg
public void msg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1)Deprecated.Logs a message, by key and file, with one parameter. This call can be used in any method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parm1- An element to be inserted into the message.
-
msg
public void msg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a message, by key and file, with two parameters. This call can be used in any method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parm1- An element to be inserted into the message.parm2- An element to be inserted into the message.
-
msg
public void msg(long type, java.lang.String className, java.lang.String methodName, java.lang.String key, java.lang.String file, java.lang.Object[] parms)Deprecated.Logs a message, by key and file, with an array of parameters. This call can be used in any method.- Specified by:
msgin interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.key- The message key.file- The name of the message file to use.parms- An array of elements to be inserted into the message.
-
textMessage
public void textMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text)Deprecated.Logs a text message (no key) with no parameters. This call can be used in a non-static method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.text- The message text.
-
textMessage
public void textMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object parm1)Deprecated.Logs a text message (no key) with one parameter. This call can be used in a non-static method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.text- The message text.parm1- An element to be displayed with the message.
-
textMessage
public void textMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a text message (no key) with two parameters. This call can be used in a non-static method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.text- The message text.parm1- An element to be displayed with the message.parm2- An element to be displayed with the message.
-
textMessage
public void textMessage(long type, java.lang.Object obj, java.lang.String methodName, java.lang.String text, java.lang.Object[] parms)Deprecated.Logs a text message (no key) with an array of parameters. This call can be used in a non-static method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.obj- The logging object ("this").methodName- The name of the logging method.text- The message text.parms- An array of elements to be displayed with the message.
-
textMessage
public void textMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text)Deprecated.Logs a text message (no key) with no parameters. This call can be used in any method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.text- The message text.
-
textMessage
public void textMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object parm1)Deprecated.Logs a text message (no key) with one parameter. This call can be used in any method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.text- The message text.parm1- An element to be displayed with the message.
-
textMessage
public void textMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object parm1, java.lang.Object parm2)Deprecated.Logs a text message (no key) with two parameters. This call can be used in any method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.text- The message text.parm1- An element to be displayed with the message.parm2- An element to be displayed with the message.
-
textMessage
public void textMessage(long type, java.lang.String className, java.lang.String methodName, java.lang.String text, java.lang.Object[] parms)Deprecated.Logs a text message (no key) with an array of parameters. This call can be used in any method.- Specified by:
textMessagein interfaceRASIMessageLogger- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.text- The message text.parms- An array of elements to be displayed with the message.
-
exception
public void exception(long type, java.lang.Object obj, java.lang.String methodName, java.lang.Exception exception)Deprecated.Logs anExceptionin a non-static method.- Parameters:
type- The type of the trace point.obj- The traced object ("this").methodName- The name of the traced method.exception- AnExceptionobject.
-
exception
public void exception(long type, java.lang.String className, java.lang.String methodName, java.lang.Exception exception)Deprecated.Logs anExceptionin a static method.- Parameters:
type- The type of the trace point.className- The name of the traced class.methodName- The name of the traced method.exception- AnExceptionobject.
-
exception
public void exception(long type, java.lang.Object obj, java.lang.String methodName, java.lang.Throwable exception)Deprecated.Logs anExceptionin a non-static method.- Specified by:
exceptionin interfaceRASIMessageLogger- Parameters:
type- The type of the trace point.obj- The traced object ("this").methodName- The name of the traced method.exception- AThrowableobject.
-
exception
public void exception(long type, java.lang.String className, java.lang.String methodName, java.lang.Throwable exception)Deprecated.Logs anExceptionin a static method.- Specified by:
exceptionin interfaceRASIMessageLogger- Parameters:
type- The type of the trace point.className- The name of the traced class.methodName- The name of the traced method.exception- AThrowableobject.
-
logMsg
protected void logMsg(long type, java.lang.String className, java.lang.String methodName, java.lang.String keyOrText, java.lang.String file, java.lang.Object[] parms, java.lang.Throwable exception)Deprecated.Generates aRASMessageEventand sends it to all attached handlers.This method assumes that any checks to see if the RAS event can be logged have already been done.
- Parameters:
type- The type of the message.className- The name of the logging class.methodName- The name of the logging method.keyOrText- The message key or message text.file- The name of the message file to use. This value may benull, if logging a text message.parms- An array of elements to be inserted into the message.exception- AThrowableobject.
-
maskValueChanged
public void maskValueChanged(RASMaskChangeEvent mc)
Deprecated.Indicates that the value of the handler's message mask has changed.This method is intended to improve the performance of the
isLoggablemethod. When notified of a change in the value of a handler's mask, the logger can update its internal data, which allows the logger to determine if a RAS event will be logged.- Specified by:
maskValueChangedin interfaceRASIMaskChangeListener- Specified by:
maskValueChangedin classRASLogger- Parameters:
mc- A mask change event, indicating what has changed.
-
-