接口 | 描述 |
---|---|
DOMLocator |
表示在源DOM节点的位置,主要用于错误报告。
|
类 | 描述 |
---|---|
DOMResult |
作为一个在一个文档对象模型形式的变换结果树架(DOM)树。
|
DOMSource |
作为一个在一个文档对象模型的形式转换源树架(DOM)树。
|
这个包实现了DOM API的具体转化。
的DOMSource
类允许这个API的实现客户端指定一个DOM Node
作为输入树的来源。如何处理与XSLT data model变压器或其他数据模型的不匹配的DOM树超出了本文的范围模型。任何来自Node
节点是合法的输入。
的DOMResult
类允许Node
规定导致DOM节点将追加。如果没有指定一个输出节点,将使用DocumentBuilder.newDocument()
创建一个输出Document
节点。如果一个节点被指定,它应该是以下之一:Document
,Element
,或DocumentFragment
。任何其他节点类型的规范是实现依赖和未定义的。如果结果是Document
,转换的输出必须设置为文档元素的单元根。
的DOMLocator
节点可以通过TransformerException
对象,并试图通过演员的TransformerException.getLocator()
结果检索方法。实施无责任使用domlocator代替一个SourceLocator
(虽然行号等不为DOM的道理),所以getlocator结果必须用instanceof测试。
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.