Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## uk.ac.man.bioinf.debug
Class Debug

    java.lang.Object
      |
      +--uk.ac.man.bioinf.debug.Debug

public class Debug
extends Object

Debug.java This forms the basis of the Debugging architecture. All debugging statements go through static methods of this class, but what is to be done with these statements is delegated to an instance of DebugInterface. This instance can be set by naming the class on the command line as the debug.debug property, or programmatically with the setInstance() methods. If this represents a change (rather than the first time the instance is set) both the old and the new instances are informed what is going on, and about each other so that Debug logs can be traced. If there is a problem with the initiation of the debug class the default is used, and information is dumped to System.out. What else can you do under such circumstances? Created: Wed Mar 1 21:59:20 2000

Version:
  $Id: Debug.java,v 1.7 2001/05/08 15:50:47 lord Exp $
Author:
  Phillip Lord

Field Summary
`static boolean` | `debug` This is the main switch variable.

Constructor Summary
`Debug()`

Method Summary
`static void` | `both(Class cla, Object message, Throwable th)`
`static void` | `both(Class cla, String message, Throwable th)`
`static void` | `both(Object obj, Object message, Throwable th)`
`static void` | `both(Object obj, String message, Throwable th)`
`static DebugInterface` | `getInstance()`
`static void` | `message(Class cla, Object message)`
`static void` | `message(Class cla, String message)`
`static void` | `message(Object obj, Object message)`
`static void` | `message(Object obj, String message)`
`static void` | `setInstance(DebugInterface deb)`
`static void` | `setInstance(String debugClass)`
`static void` | `throwable(Class cla, Throwable th)`
`static void` | `throwable(Object obj, Throwable th)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### debug

    public static final boolean debug

  This is the main switch variable. It if is set to true before the compile then any assertions or debug statements within the code will be left in place, and will impose a runtime penalty. If it is set to false, before the compile then those assertions will be optimised away.

  See Also:
    Constant Field Values

Constructor Detail

### Debug

    public Debug()

Method Detail

### setInstance

    public static void setInstance(DebugInterface deb)

### setInstance

    public static void setInstance(String debugClass)

### getInstance

    public static DebugInterface getInstance()

### message

    public static void message(Object obj,
                               String message)

### message

    public static void message(Object obj,
                               Object message)

### message

    public static void message(Class cla,
                               String message)

### message

    public static void message(Class cla,
                               Object message)

### throwable

    public static void throwable(Object obj,
                                 Throwable th)

### throwable

    public static void throwable(Class cla,
                                 Throwable th)

### both

    public static void both(Object obj,
                            String message,
                            Throwable th)

### both

    public static void both(Class cla,
                            String message,
                            Throwable th)

### both

    public static void both(Object obj,
                            Object message,
                            Throwable th)

### both

    public static void both(Class cla,
                            Object message,
                            Throwable th)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD