[jboss-user] [JBoss Seam] - Re: Seam Logger return NullPointerException

terryb do-not-reply at jboss.com
Mon Sep 17 21:33:52 EDT 2007


Hi and thank you, I understood my first problem that not to instantiate seam managed objects.

however, I am still not clear about injection. Not sure what wrong I am doing there. Please see below, why does seamLogger.info(...) return NullPointerException?

import org.jboss.seam.annotations.Logger; 
import org.jboss.seam.log.Log; 
... 

@Name("activityLogger") 
public class ActivityLogger { 

 @Logger 
 Log seamLogger; 

 ... 

 public void log() { 
  seamLogger.info("seam logger test #0", "ok"); <-- line throwing exception 
 } 
} 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4085298#4085298

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4085298



More information about the jboss-user mailing list