在不用spring框架的情况下如何使用 log4j?
一样的做法么 如果是
<!--====================== log4jConfigLocation 日志文件配置======================--> <context-param>
<param-name>webAppRootKey</param-name>
<param-value>CaBossMgrServicePath</param-value>
</context-param>
<context-param>
<param-name>log4jConfigLocation</param-name>
<param-value>/WEB-INF/log4j.properties</param-value>
</context-param>
<context-param>
<param-name>log4jRefreshInterval</param-name>
<param-value>6000</param-value>
</context-param>
<listener>
<listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
<listener>
监听器 应该 用哪个呢~~~还想问下 各位 一般用log4j的时候一般是用什么框架的~~
一样的做法么 如果是
<!--====================== log4jConfigLocation 日志文件配置======================--> <context-param>
<param-name>webAppRootKey</param-name>
<param-value>CaBossMgrServicePath</param-value>
</context-param>
<context-param>
<param-name>log4jConfigLocation</param-name>
<param-value>/WEB-INF/log4j.properties</param-value>
</context-param>
<context-param>
<param-name>log4jRefreshInterval</param-name>
<param-value>6000</param-value>
</context-param>
<listener>
<listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
<listener>
监听器 应该 用哪个呢~~~还想问下 各位 一般用log4j的时候一般是用什么框架的~~
Logger log = Logger.getLogger(XXOO.class);
这个XXOO,代表所在类的类名。