BEA WebLogic Server Bedienungsanleitung Seite 75

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 88
  • Inhaltsverzeichnis
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 74
How Loggable Objects Are Used
Internationalization Guide C-3
logIOErrorLoggable (Throwable)—returns a Loggable object
The
Loggable class can be used as shown in Listing C-2.
Listing C-2 Example of Use of Loggable Class
package test;
import weblogic.logging.Loggable;
import weblogic.i18n.testLogger;
...
try {
// some IO
} catch (IOException ioe) {
Loggable l = testLogger.logIOErrorLoggable(ioe);
l.log(); // log the error
throw new Exception(l.getMessage());//throw new exception with
same text as logged
}
Seitenansicht 74
1 2 ... 70 71 72 73 74 75 76 77 78 79 80 ... 87 88

Kommentare zu diesen Handbüchern

Keine Kommentare