-----------------------------
Please read the FAQ!
<http://java.apache.org/faq/>
-----------------------------

> Can a few of you who have dealt with this issue shed
> some light on successful techniques you have used.

My 2.5 cents worth.

For my servlets I wrote a class called Logger which basically maintains
various logging functions for my servlets.  Everything in it is declared
as static and it basically contains methods to do logging to a log file.
In the code, you can set a log level. Then, when you want to log
something you use a logging command:

        Logger.info(String...)
        Logger.crit(String...)
        Logger.debug(String...)
        Logger.data(String...)

Based on the "loglevel" setting in the class, these commands will either
log to a file or do nothing. This enables you to still have nice
looking, readable code.

Hope it helps,
Paul


--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html/>
Problems?:           [EMAIL PROTECTED]

Reply via email to