- public static void trace(String message)
- {
- if (initLogger())
- {
- log.trace(message, null);
- }
- else
- {
- System.out.println(message);
- }
- }
-
- public static void trace(String message, Throwable t)
- {
- if (initLogger())
- {
- log.trace(message, t);
- }
- else
- {
- System.out.println(message);
- t.printStackTrace();
- }
- }
-
- public static void debug(String message)
- {
- if (initLogger())
- {
- log.debug(message, null);
- }
- else
- {
- System.out.println(message);
- }
-
- }
-
- public static void debug(String message, Throwable t)
- {
- if (initLogger())
- {
- log.debug(message, t);
- }
- else
- {
- System.out.println(message);
- t.printStackTrace();
- }
-
- }
-
- public static void info(String message)
- {
- if (initLogger())
- {
- log.info(message, null);
- }
- else
- {
- System.out.println(message);
- }
-
- }
-
- public static void info(String message, Throwable t)
- {
- if (initLogger())
- {
- log.info(message, t);
- }
- else
- {
- System.out.println(message);
- t.printStackTrace();
- }
-
- }
-
- public static void warn(String message)
- {
- if (initLogger())
- {
- log.warn(message, null);
- }
- else
- {
- System.out.println(message);
- }
-
- }
-
- public static void warn(String message, Throwable t)
- {
- if (initLogger())
- {
- log.warn(message, t);
- }
- else
- {
- System.out.println(message);
- t.printStackTrace();
- }
-
- }
-
- public static void error(String message)
- {
- if (initLogger())
- {
- log.error(message, null);
- }
- else
- {
- System.err.println(message);
- }
-
- }
-
- public static void error(String message, Throwable t)
- {
- if (initLogger())
- {
- log.error(message, t);
- }
- else
- {
- System.err.println(message);
- t.printStackTrace(System.err);
- }
-
- }
-
- public static void fatal(String message)
- {
- if (initLogger())
- {
- log.fatal(message, null);
- }
- else
- {
- System.err.println(message);
- }
-
- }
-
- public static void fatal(String message, Throwable t)
- {
- if (initLogger())
- {
- log.fatal(message, t);
- }
- else
- {
- System.err.println(message);
- t.printStackTrace(System.err);
- }
-
- }
-
- public static boolean isDebugEnabled()
- {
- return log == null ? false : log.isDebugEnabled();
- }
-
- public static boolean isTraceEnabled()
- {
- return log == null ? false : log.isTraceEnabled();
- }
-