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

## javazoom.download.util
Class Debug

    java.lang.Object
      |
      +--javazoom.download.util.Debug

public class Debug
extends java.lang.Object

This class implements simple trace for Download4J.
[Time] full qualified classname: Message

Field Summary
`static java.lang.String` | `DATEFORMAT` Date format for traces : Default is yyyy/MM/dd HH:mm
`static int` | `DEBUG`
`static int` | `INFO`
`static int` | `PANIC`

Method Summary
`void` | `close()` Flushes and closes the output.
`static Debug` | `getInstance()` Gets the Debug instance for traces.
`int` | `getLogLevel()` Gets level of traces.
`void` | `setFileWriter(java.lang.String filename)` Sets fileERR as messages output
`void` | `setLogLevel(int lev)` Sets level of traces. 0 : PANIC 1 : PANIC + INFO 2 : PANIC + INFO + DEBUG
`void` | `setStdErrWriter()` Sets Standard ERR as messages output.
`void` | `setStdOutWriter()` Sets Standard OUT as messages output.
`void` | `trace(int level, java.lang.String message)` Traces message to output.

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

Field Detail

### DATEFORMAT

    public static java.lang.String DATEFORMAT

  Date format for traces : Default is yyyy/MM/dd HH:mm

### PANIC

    public static int PANIC

### INFO

    public static int INFO

### DEBUG

    public static int DEBUG

Method Detail

### getInstance

    public static Debug getInstance()

  Gets the Debug instance for traces.

  Returns:
    Debug instance

### setStdErrWriter

    public void setStdErrWriter()

  Sets Standard ERR as messages output.

### setStdOutWriter

    public void setStdOutWriter()

  Sets Standard OUT as messages output.

### setFileWriter

    public void setFileWriter(java.lang.String filename)
                       throws java.io.IOException

  Sets fileERR as messages output

  Parameters:
    `filename` - for traces
  Throws:
    `java.io.IOException`

### close

    public void close()

  Flushes and closes the output.

### trace

    public void trace(int level,
                      java.lang.String message)

  Traces message to output.

  Parameters:
    `level` - of trace
    `message` - to log

### getLogLevel

    public int getLogLevel()

  Gets level of traces.

  Returns:
    level of traces.

### setLogLevel

    public void setLogLevel(int lev)

  Sets level of traces. 0 : PANIC
  1 : PANIC + INFO
  2 : PANIC + INFO + DEBUG

  Parameters:
    `lev` - level of traces.

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