All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.ups.xmlsdk.util.logging.Logger

java.lang.Object
   |
   +----com.ups.xmlsdk.util.logging.Logger

public class Logger
extends Object
implements LogDefs, LogContextFactory
General Logging interface. There is one interface per facility so the user does not have to specify the facility string. The user can also specify a context factory which looks up user context information using the calling thread as a key. This allows use of the two shorthand log() methods that do not have an explicit context arg. The default factory prints the process and thread IDs.


Constructor Index

 o Logger(String, Logger)

Method Index

 o audit(String)
 o close()
 o debug(String)
 o error(String)
 o flush()
 o getContext()
 o getFacility()
 o getFormatter()
 o getLevel()
 o log(int, String)
 o log(int, String, long)
 o log(LogContext, String, int, String, long)
 o log(String)
 o parseLevel(String)
Parse a logging level represented as a string.
 o setContextFactory(LogContextFactory)
 o setFacility(String)
 o setFormatter(LogFormatter)
 o setLevel(int)
 o trace(String)

Constructors

 o Logger
 public Logger(String facility,
               Logger delegate)

Methods

 o audit
 public final void audit(String msg)
 o close
 public void close() throws IOException
 o debug
 public final void debug(String msg)
 o error
 public final void error(String msg)
 o flush
 public void flush() throws IOException
 o getContext
 public LogContext getContext()
 o getFacility
 public String getFacility()
 o getFormatter
 public LogFormatter getFormatter()
 o getLevel
 public int getLevel()
 o log
 public final void log(int pri,
                       String msg)
 o log
 public final void log(int pri,
                       String msg,
                       long code)
 o log
 public int log(LogContext context,
                String facility,
                int priority,
                String msg,
                long code) throws LogException
 o log
 public final void log(String msg)
 o parseLevel
 public static final int parseLevel(String s)
Parse a logging level represented as a string. Return -1 if a valid level cannot be parsed.

 o setContextFactory
 public void setContextFactory(LogContextFactory contextFactory)
 o setFacility
 public void setFacility(String facility)
 o setFormatter
 public void setFormatter(LogFormatter formatter)
 o setLevel
 public void setLevel(int level)
 o trace
 public final void trace(String msg)

All Packages  Class Hierarchy  This Package  Previous  Next  Index