1.下载eclipse与log4j相关软件
2.在eclipse中建立一个java项目,比如helloeclipse,在此过程中add 外部jar log4j.jar文件 【程序编程相关:小小姑娘清晨起床 提着裤子上茅房 茅房里】 【推荐阅读:爱死北大了~强多作业】3.利用eclipse的import功能引入log4j.properties文件,并且进行修改,log4j在你下载的log4j包的example/lf/lf5里就有 【扩展信息:下载信息内容时文件名称的指定】 如下: # for the general syntax of property based configuration files see the # documenation of org.apache.log4j.propertyconfigurator.# the root category uses the appender called a1. since no priority is
# specified, the root category assumes the default priority for root # which is debug in log4j. the root category is the only category that # has a default priority. all other categories need not be assigned a # priority in which case they inherit their priority from the ... 下一页