net.sourceforge.jgrib.examples
Class SetupLog
java.lang.Object
net.sourceforge.jgrib.examples.SetupLog
public class SetupLog
- extends java.lang.Object
Demonstration class.
Demonstrate how to get access to DEBUG information from the
JGRIB library. Logging is based upon Log4J, so we test before
using the library whether Log4J is allready configured.
This way the standard Log4J warnings can be turned off, if
no logging is desired.
If Log4J is configured the JGRIB library will not touch the
configuration.
Together with this class you will find a config directory
holding:
- jgrib_log4j.xml
- log4j.dtd
They are used in the example method in this class, which will
turn debugging information from JGRIB on, and direct it to
a file named in the jgrib_log4j.xml file.
- Author:
- frv_peg
E-mail: frv_peg at users.sourceforge.net
Method Summary |
static void |
addJGribDebugInfo()
Method: AddJGribDebugInfo()
Call this if you want debug output written to a file. |
static void |
main(java.lang.String[] args)
Method: main
Use it for testing purposes. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SetupLog
public SetupLog()
addJGribDebugInfo
public static void addJGribDebugInfo()
- Method: AddJGribDebugInfo()
Call this if you want debug output written to a file.
Make sure, that you have write access and isn't violating the
settings in the SecurityManager, if applied.
Check settings in "config/jgrib_log4j.xml"
main
public static void main(java.lang.String[] args)
- Method: main
Use it for testing purposes.
- Parameters:
args
- - Totally ignored