--- Naresh Sharma <[EMAIL PROTECTED]> wrote:
> Hello Everybody,
> 
> 
> Well my understanding about Category is that we can have our own
> categories and there must be category declared in the properties
> file,
> for which we can call like this
> 
>         static Category CAT =
> Category.getInstance(Sort.class.getName());
> 
> in this case their should be a category with fully qualified name of
> Sort class declared in Properties file.
> 

No. Categories do not have to be explicitly declared. They can be
created "on the fly" so to speak.

> Now when i looked in to the example code in which property file  have
> following as the root directory value
> 
>     log4j.rootCategory=, A1, A2
> 
> and still in the code we can use this command.
> 
>     static Category CAT = Category.getInstance(Sort.class.getName());
> 
> Now my question is that how this is returning the category with fully
> qualified name of the sort class.
> 

Categories are part of a tree hierarchy, rooted at root. Each child
inherits the properties of its parent, and may override any properties
it wishes. Thus, in your properties file you can define the
characteristics of the root category and know that your Sort category
will inherit them. Thus your properties file knows nothing about Sort
yet you can set up the characteristics for the Sort category!

> I guess i am missing something, please let me know and if publish
> sample
> property file for defining custom property file, if possible.
> 

You're missing the hierarchical nature of categories I mentioned above.

> 
> Thanks a lot
> Naresh
> 
> 
> 
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


=====
Don

__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to