Title: RE: how to log debug message in Axis
http://jakarta.apache.org/log4j/docs/documentation.html
 
In your class you will need to have something like this:
 
import org.apache.log4j.Category;
public class Boo
{
  private static Category log=Category.getInstance(Boo.class.getName());
  private String value;
  private int len;
 
  public setValue(String newValue){
    if(log.isDebugEnabled()){
        log.debug(" ++setValue");
        log.debug("new Value is:"+newValue);
    }
 
    try{
        len=newValue.length();
    }catch(NullPointerException e){
        log.error("newValue was null. Stacktrace attached.",e);
    }
.....
-----Original Message-----
From: Jianlin Chang [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 15, 2002 9:58 AM
To: Koen Weyn; [EMAIL PROTECTED]
Subject: RE: how to log debug message in Axis

With regard to reply from Koen Weyn, how do I insert code using log4j facility in my own handlers?  Where can I find relevant docs?  Thanks.

     -----Original Message-----
    From:   Jianlin Chang 
    Sent:   Thursday, February 14, 2002 8:31 PM
    To:     '[EMAIL PROTECTED]'
    Subject:        how to log debug message in Axis

    How to log debug message in Axis?  Suppose that I want to do this within the handlers.  Thanks.

Reply via email to