|
WebLogic Server 7.0 Code Examples, BEA Systems, Inc. | |||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||
java.lang.Object | +--examples.i18n.logging.I18nLog
This example shows how to use the internationalized (I18n) logging interface to access a simple message catalog. The methods and arguments are defined in the I18nLog.xml catalog. This example uses the simple message catalog I18nSimple.xml.
The following section describes how to build and run the examples:
We provide a build script for you to build the example, called build.xml.
prompt> ant
The script builds the example and places the files in the samples\examples\i18n\logging directory of your WebLogic Server installation.
These scripts process the I18nLog.xml catalog, and produce the logging class examples.i18n.logging.I18nLogLogger. This class contains static methods for logging messages to the WebLogic Server error log.
prompt> java examples.i18n.logging.I18nLog
java weblogic.il8ntools.gui.MessageEditor
The message ID is used to obtain the message attributes. The L10nLookup object provides access to the catalogs via Localizer classes. Localizers provide the access to individual messages. Each log message catalog has two Localizers:
You will need to get the L10nLookup properties and use them to get the message Localizers. The basic localizer lcl returns a default value of false, and the detail localizer lclDetail returns a default value of true.
In addition to the basic information described above, the detail Localizer provides additional information, including cause and action for the message. Copyright (c) 2000-2002 by BEA Systems, Inc. All Rights Reserved.
| Constructor Summary | |
I18nLog()
|
|
| Method Summary | |
static void |
main(java.lang.String[] argv)
|
| Methods inherited from class java.lang.Object |
|
| Constructor Detail |
public I18nLog()
| Method Detail |
public static void main(java.lang.String[] argv)
|
Documentation is available at http://e-docs.bea.com/wls/docs70 |
|||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||