All Packages  This Package  Class Hierarchy  Class Search  Index

Class kh.util.Debug
java.lang.Object
   |
   +----kh.util.Debug

  Summary

public class  Debug
     extends java.lang.Object
{
          // Fields 7
     public static final int CRITICAL;
     public static final int DEBUG;
     public static final int ERROR;
     public static final int INFO;
     public static final int PROFILE_DATA;
     public static final int ULTRA_DEBUG;
     public static final int WARNING;

          // Constructors 1
     public Debug();

          // Methods 12
     public static void criticalln(Object);
     public static void debugln(Object);
     public static void errorln(Object);
     public static void exception(Throwable);
     public static int getLogThreshold();
     public static void infoln(Object);
     public static boolean isThreadDisplay();
     public static void println(Object, int);
     public static void setLogThreshold(int);
     public static void setThreadDisplay(boolean);
     public static void udebugln(Object);
     public static void warnln(Object);

}

This class is a central diagnostic print engine.

Features include:




  Fields

· CRITICAL

Summary  |  Top

   public static final int CRITICAL


· DEBUG

Summary  |  Top
   public static final int DEBUG


· ERROR

Summary  |  Top
   public static final int ERROR


· INFO

Summary  |  Top
   public static final int INFO


· PROFILE_DATA

Summary  |  Top
   public static final int PROFILE_DATA


· ULTRA_DEBUG

Summary  |  Top
   public static final int ULTRA_DEBUG


· WARNING

Summary  |  Top
   public static final int WARNING


  Constructors

· Debug

Summary  |  Top

   public Debug() 

Default constructor



  Methods

· criticalln

Summary  |  Top
   public static void criticalln(Object obj) 

Shorthand for println(obj, CRITICAL)



· debugln

Summary  |  Top
   public static void debugln(Object obj) 

Shorthand for println(obj, DEBUG)



· errorln

Summary  |  Top
   public static void errorln(Object obj) 

Shorthand for println(obj, ERROR)



· exception

Summary  |  Top
   public static void exception(Throwable e) 

Prints a descriptive message about the specified exception and continues execution

Parameter Description
e the exception



· getLogThreshold

Summary  |  Top
   public static int getLogThreshold() 

Returns the minimum threshold needed to print the error to out. If not set programmatically, it will be set by using the value in the "kh.debug.threshold" property.

Returns:
the threshold


· infoln

Summary  |  Top
   public static void infoln(Object obj) 

Shorthand for println(obj, INFO)



· isThreadDisplay

Summary  |  Top
   public static boolean isThreadDisplay() 

Returns true if the thread names should be shown. If not set programmatically, it will be set by using the value in the "kh.debug.showthreads" property.

Returns:
whether thread names will be shown


· println

Summary  |  Top
   public static void println(Object obj, 
                              int priority) 

Prints a message with the specified priority level, priority levels range from 0 (informational) to 100 (critical).

Parameter Description
obj the thing to be converted to a string
priority the debug level



· setLogThreshold

Summary  |  Top
   public static void setLogThreshold(int newthresh) 

Sets the level at which messages are logged

Parameter Description
newthresh the new threshold value



· setThreadDisplay

Summary  |  Top
   public static void setThreadDisplay(boolean flag) 

Turns on/off the display of thread names

Parameter Description
flag on or off



· udebugln

Summary  |  Top
   public static void udebugln(Object obj) 

Shorthand for println(obj, ULTRA_DEBUG)



· warnln

Summary  |  Top
   public static void warnln(Object obj) 

Shorthand for println(obj, WARNING)



All Packages  This Package  Class Hierarchy  Class Search  Index
Freshly brewed Java API Documentation automatically generated with polardoc Version 1.0.7