Listing 2 shows a sample Log4J configuration file that configures a FileAppender.
清单2给出了一个Log4J的样例配置文件,它负责配置FileAppender。
In this configuration, error messages under the com.ambrosesoft.log.MyClass category are sent to the FileAppender, which in turn writes them to a file called log.txt.
在这种配置中,com.ambrosesoft.log.MyClass类中的错误消息被发送给FileAppender,后者将其写入一个名为 log.txt 的文件中。
In this configuration, error messages under the com.ambrosesoft.log.MyClass category are sent to the FileAppender, which in turn writes them to a file called log.txt.
在这种配置中,com.ambrosesoft.log.MyClass类中的错误消息被发送给FileAppender,后者将其写入一个名为 log.txt 的文件中。
应用推荐