You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Richard Crawford <ri...@aepona.com> on 2001/09/07 12:57:02 UTC

Category Priorities

Hi there, I have a question regarding Category Priorities.

I am using class

com.mycompany.product.MyApplication (which declares its own Category
with the same name)



and my Log4J properties file specifies a priority of DEBUG for
com.mycompany.product classes

- this is fine in use, with Log4J doing what it is supposed to.


However, if I try to obtain the Priority of my class at runtime using
cat.getPriority(), I receive a NullPointerException.

I then tried cat.getRoot().getPriority(), which works.  I haven`t
explicitly set the priority on any other com.mycompany.product classes,
yet a Priority is available.  Why does com.mycompany.product not inherit
this property?

Thanks in advance,

Richard.

-- 
Richard Crawford <ri...@aepona.com>
AePONA Ltd. Interpoint Building
20-24 York Street, Belfast
BT15 1AQ, N.Ireland

Phone: +44 2890 275238
Fax:   +44 2890 269111

"The future`s so dull I`ve gotta sing torch songs"

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org