Log4j ( choose one appender to use everytime after a test )



I want to integrate the log4j in a wab application, but the problem is that I have to check if the application is executed on which operation system and then if it's a "Windows" put the logs in a file and if it's "Unix " show the logs on a console.


so if someone know how can I choose or specify just one appender to use, I will be thankfull ? because all the configuration for the log4j is in (Xml or propreties file )


for exemple i can check if an booleen is false ( show on the console ) and if not ( put the logs to the file log.out ) !


Thank you for ur interest .


No comments:

Post a Comment