<?xml version="1.0" encoding="UTF-8" ?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
--> <!-- Authors: Chris Taylor, Ceki Gulcu. --> <!-- Version: 1.2 --> <!-- A configuration element consists of optional renderer
elements,appender elements, categories and an optional root
element. --> <!ELEMENT log4j:configuration (renderer*, throwableRenderer?,
appender*,plugin*, (category|logger)*,root?,
(categoryFactory|loggerFactory)?)> <!-- The "threshold" attribute takes a level value below which -->
<!-- all logging statements are disabled. --> <!-- Setting the "debug" enable the printing of internal log4j logging -->
<!-- statements. --> <!-- By default, debug attribute is "null", meaning that we not do touch -->
<!-- internal log4j logging settings. The "null" value for the threshold -->
<!-- attribute can be misleading. The threshold field of a repository -->
<!-- cannot be set to null. The "null" value for the threshold attribute -->
<!-- simply means don't touch the threshold field, the threshold field -->
<!-- keeps its old value. --> <!ATTLIST log4j:configuration
xmlns:log4j CDATA #FIXED "http://jakarta.apache.org/log4j/"
threshold (all|trace|debug|info|warn|error|fatal|off|null) "null"
debug (true|false|null) "null"
reset (true|false) "false"
> <!-- renderer elements allow the user to customize the conversion of -->
<!-- message objects to String. --> <!ELEMENT renderer EMPTY>
<!ATTLIST renderer
renderedClass CDATA #REQUIRED
renderingClass CDATA #REQUIRED
> <!-- throwableRenderer allows the user to customize the conversion
of exceptions to a string representation. -->
<!ELEMENT throwableRenderer (param*)>
<!ATTLIST throwableRenderer
class CDATA #REQUIRED
> <!-- Appenders must have a name and a class. -->
<!-- Appenders may contain an error handler, a layout, optional parameters -->
<!-- and filters. They may also reference (or include) other appenders. -->
<!ELEMENT appender (errorHandler?, param*,
rollingPolicy?, triggeringPolicy?, connectionSource?,
layout?, filter*, appender-ref*)>
<!ATTLIST appender
name CDATA #REQUIRED
class CDATA #REQUIRED
> <!ELEMENT layout (param*)>
<!ATTLIST layout
class CDATA #REQUIRED
> <!ELEMENT filter (param*)>
<!ATTLIST filter
class CDATA #REQUIRED
> <!-- ErrorHandlers can be of any class. They can admit any number of -->
<!-- parameters. --> <!ELEMENT errorHandler (param*, root-ref?, logger-ref*, appender-ref?)>
<!ATTLIST errorHandler
class CDATA #REQUIRED
> <!ELEMENT root-ref EMPTY> <!ELEMENT logger-ref EMPTY>
<!ATTLIST logger-ref
ref CDATA #REQUIRED
> <!ELEMENT param EMPTY>
<!ATTLIST param
name CDATA #REQUIRED
value CDATA #REQUIRED
> <!-- The priority class is org.apache.log4j.Level by default -->
<!ELEMENT priority (param*)>
<!ATTLIST priority
class CDATA #IMPLIED
value CDATA #REQUIRED
> <!-- The level class is org.apache.log4j.Level by default -->
<!ELEMENT level (param*)>
<!ATTLIST level
class CDATA #IMPLIED
value CDATA #REQUIRED
> <!-- If no level element is specified, then the configurator MUST not -->
<!-- touch the level of the named category. -->
<!ELEMENT category (param*,(priority|level)?,appender-ref*)>
<!ATTLIST category
class CDATA #IMPLIED
name CDATA #REQUIRED
additivity (true|false) "true"
> <!-- If no level element is specified, then the configurator MUST not -->
<!-- touch the level of the named logger. -->
<!ELEMENT logger (param*,level?,appender-ref*)>
<!ATTLIST logger
class CDATA #IMPLIED
name CDATA #REQUIRED
additivity (true|false) "true"
> <!ELEMENT categoryFactory (param*)>
<!ATTLIST categoryFactory
class CDATA #REQUIRED> <!ELEMENT loggerFactory (param*)>
<!ATTLIST loggerFactory
class CDATA #REQUIRED> <!ELEMENT appender-ref EMPTY>
<!ATTLIST appender-ref
ref CDATA #REQUIRED
> <!-- plugins must have a name and class and can have optional parameters -->
<!ELEMENT plugin (param*, connectionSource?)>
<!ATTLIST plugin
name CDATA #REQUIRED
class CDATA #REQUIRED
> <!ELEMENT connectionSource (dataSource?, param*)>
<!ATTLIST connectionSource
class CDATA #REQUIRED
> <!ELEMENT dataSource (param*)>
<!ATTLIST dataSource
class CDATA #REQUIRED
> <!ELEMENT triggeringPolicy ((param|filter)*)>
<!ATTLIST triggeringPolicy
name CDATA #IMPLIED
class CDATA #REQUIRED
> <!ELEMENT rollingPolicy (param*)>
<!ATTLIST rollingPolicy
name CDATA #IMPLIED
class CDATA #REQUIRED
> <!-- If no priority element is specified, then the configurator MUST not -->
<!-- touch the priority of root. -->
<!-- The root category always exists and cannot be subclassed. -->
<!ELEMENT root (param*, (priority|level)?, appender-ref*)> <!-- ==================================================================== -->
<!-- A logging event -->
<!-- ==================================================================== -->
<!ELEMENT log4j:eventSet (log4j:event*)>
<!ATTLIST log4j:eventSet
xmlns:log4j CDATA #FIXED "http://jakarta.apache.org/log4j/"
version (1.1|1.2) "1.2"
includesLocationInfo (true|false) "true"
> <!ELEMENT log4j:event (log4j:message, log4j:NDC?, log4j:throwable?,
log4j:locationInfo?, log4j:properties?) > <!-- The timestamp format is application dependent. -->
<!ATTLIST log4j:event
logger CDATA #REQUIRED
level CDATA #REQUIRED
thread CDATA #REQUIRED
timestamp CDATA #REQUIRED
time CDATA #IMPLIED
> <!ELEMENT log4j:message (#PCDATA)>
<!ELEMENT log4j:NDC (#PCDATA)> <!ELEMENT log4j:throwable (#PCDATA)> <!ELEMENT log4j:locationInfo EMPTY>
<!ATTLIST log4j:locationInfo
class CDATA #REQUIRED
method CDATA #REQUIRED
file CDATA #REQUIRED
line CDATA #REQUIRED
> <!ELEMENT log4j:properties (log4j:data*)> <!ELEMENT log4j:data EMPTY>
<!ATTLIST log4j:data
name CDATA #REQUIRED
value CDATA #REQUIRED
>

  

log4j.dtd的更多相关文章

  1. 应验log4j.xml时不能找到log4j.dtd

    原因分析:log4j.xml中使用log4j的DTD验证其格式的有效性"<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd&quo ...

  2. org.apache.log4j.Logger详解

    org.apache.log4j.Logger 详解 1. 概述 1.1. 背景 在应用程序中添加日志记录总的来说基于三个目的 :监视代码中变量的变化情况,周期性的记录到文件中供其他应用进行统计分析工 ...

  3. log4j.xml的实用例子

    大多数讲log4j配置的教程用的都是log4j.properties文件,我觉得xml或许更好一点,在这里我提供一个我已经用于生产环境的log4j.xml的例子,先上代码,然后再解释: <?xm ...

  4. slf4j log4j logback关系详解和相关用法

    slf4j log4j logback关系详解和相关用法 写java也有一段时间了,一直都有用slf4j log4j输出日志的习惯.但是始终都是抱着"拿来主义"的态度,复制粘贴下配 ...

  5. log4j日志文件 log4j.xml log4j.properties配置

    1,导入log4j  jar包; 2,配置log4j.xml或log4j.properties文件; ------------------------------------------------- ...

  6. LogBack,升级版的log4J

    <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE log4j:configuration SYS ...

  7. log4j配置说明

    log4j appender :用于指定使用的append类 logger:定义logger的名称和其对应的appender LoggerFactory.getLogger("counter ...

  8. springmvc+log4j操作日志记录,详细配置

    没有接触过的,先了解一下:log4j教程 部分内容来:log4j教程 感谢! 需要导入包: log包:log4j-12.17.jar 第一步:web.xml配置 <!-- log4j配置,文件路 ...

  9. Log4j配置说明及样例

    一般的应用都会记录日志,Java圈里面用得最多就属log4j了,比较规范一点就是使用log4j.xml进行配置Log输出.这里就比较有疑问,多数情况是使用log4j.properties文件呐,前面也 ...

随机推荐

  1. Python之运算符以及基本数据类型的object

    一.运算符 1.算术运算符 % 求余运算 **   幂-返回x的y次幂 //   取整数-返回商的整数部分,例:9//2输出结果是4 2.比较运算符 == 等于 != 不等于 <> 不等于 ...

  2. 基于XML的类的属性的装配

    基于XML的属性装配 1.手动装配 <!-- 属性的装配:手动装配 --> <bean id="userService" class="com.neue ...

  3. idea 新建maven项目没有src及其子目录问题

    注意在这一步中,填写maven的本地地址还有手动修改settings地址非常重要!!! 如果你是第一次配置maven,少配置任何一个将导致你以后建立的mvn项目全部没有src目录!!! 解决办法就是卸 ...

  4. python编程技巧

  5. zookeeper客户端使用原生JavaApi操作节点

    1.引入依赖 <dependency> <groupId>org.apache.zookeeper</groupId> <artifactId>zook ...

  6. js 点击图片放大,再点击缩小还原

    <!doctype html> <html lang="en"> <head> <meta charset="UTF-8&quo ...

  7. Unity 移动 和 旋转 [小结]

    [移动]  Position: 说明: 直接修改位置数据  Translate: 说明: [匀速]朝着一个方向,一直移动. (dir * speed 可以控制速度)适合键盘控制物体上下左右运动 函数: ...

  8. C++_静态类成员

    在C++中,静态成员是属于整个类的而不是某个对象. 静态成员变量只存储一份供所有对象共用,所以在所有对象中都可以共享它. 使用静态成员变量实现多个对象之间的数据共享不会破坏隐藏的原则,保证了安全性还可 ...

  9. 读经典——《CLR via C#》(Jeffrey Richter著) 笔记_友元程序集

    [应用场景] 程序集A访问程序集B定义的Internal访问类型的类的成员. [使用方式] 在构建程序集B的时候,引入System.Runtime.CompilerServices,以此来添加Inte ...

  10. 74th LeetCode Weekly Contest Number of Subarrays with Bounded Maximum

    We are given an array A of positive integers, and two positive integers L and R (L <= R). Return ...