************************************************************************
* How to use logging in HDFView and HDF-JAVA Library                   *
************************************************************************

HDFView has implemented logging in the java code with support for the
slf4j 2.0.* package. HDFView by default uses the slf4j-nop-2.0.*.jar.
This suppresses any logging information. See http://www.slf4j.org/ for
more information on the slf4j package.

To enable logging in HDFView, you must use the slf4j-simple-2.0.*.jar
 (or other slf4j compatible jar file) by overriding the default slf4j-nop-2.0.*.jar file.

HDFView:
  To enable logging in HDFView requires editing the HDFView.cfg file in the HDFView/app folder.
  change line 25: app.classpath=$APPDIR/slf4j-nop-2.0.*.jar
  to: app.classpath=$APPDIR

  Next move the file slf4j-nop-2.0.*.jar in the HDFView/app folder to the  HDFView/app/extra folder.
  And move the file slf4j-nop-2.0.*.jar in the HDFView/app/mods folder to the  HDFView/app/mods/extra folder.

  The file HDFViewLogger.log file will be written in the folder specified by HDFView root.
  HDFView root is displayed in the status bar of HDFView.

org.slf4j.simpleLogger.defaultLogLevel is the default log level for all instances of SimpleLogger.
It must be one of ("trace", "debug", "info", "warn", or "error"). If not specified, defaults to "info".

************************************************************************
* Example use of logging and the HDF5 JAVA Library                          *
************************************************************************
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class H5test {
    /**
     * Add logger for this class
     */

    private static final Logger log = LoggerFactory.getLogger(H5test.class);

    ...
    public int H5function (int arg)
    {
        log.info("H5function called with {}", arg);
        if (arg < 0) {
            log.warn("H5function with negative argument");
            return 0;
        }
        try {
            some_function();
        }
        catch (Exception ex) {
            log.debug("some_function failed: ", ex);
        }

        log.trace("H5function finished");

        return (arg * 3);
    }

