# Uses of Class
nu.xom.Document

Packages that use Document
Package
Description
nu.xom
`nu.xom` is the core package of XOM that contains all the basic classes representing the different kinds of nodes: elements, attributes, comments, text nodes, and so forth.
nu.xom.converters
`nu.xom.converters` contains classes that convert XOM documents to other models such as SAX and DOM.
nu.xom.tests
`nu.xom.tests` contains the JUnit based test suite for XOM.
nu.xom.xinclude
`nu.xom.xinclude` supports XInclude processing of XOM documents and elements.
nu.xom.xslt
`nu.xom.xslt` connects XOM documents to TrAX-based XSLT processors.

## Uses of Document in nu.xom

Methods in nu.xom that return Document
Modifier and Type
Method
Description
`Document`
Builder.`build(File in)`
Reads the document from a file.
`Document`
Builder.`build(InputStream in)`
Reads the document from an input stream.
`Document`
Builder.`build(InputStream in, String baseURI)`
Reads the document from an input stream while specifying a base URI (which need not be the stream's actual URI).
`Document`
Builder.`build(Reader in)`
Reads the document from a reader.
`Document`
Builder.`build(Reader in, String baseURI)`
Reads the document from a character stream while specifying a base URI.
`Document`
Builder.`build(String systemID)`
Parses the document at the specified URL.
`Document`
Builder.`build(String document, String baseURI)`
Reads the document from the contents of a string.
`Document`
Document.`copy()`
Returns a complete copy of this document.
`final Document`
Node.`getDocument()`
Returns the document that contains this node, or null if this node is not currently part of a document.
`Document`
ValidityException.`getDocument()`
Returns a `Document` object for the document that caused this exception.
`Document`
NodeFactory.`startMakingDocument()`
Creates a new `Document` object.
Methods in nu.xom with parameters of type Document
Modifier and Type
Method
Description
`void`
NodeFactory.`finishMakingDocument(Document document)`
Signals the end of a document.
`void`
Serializer.`write(Document doc)`
Serializes a document onto the output stream using the current options.
Constructors in nu.xom with parameters of type Document
Modifier
Constructor
Description
``
`Document(Document doc)`
Creates a copy of this document.

## Uses of Document in nu.xom.converters

Methods in nu.xom.converters that return Document
Modifier and Type
Method
Description
`static Document`
DOMConverter.`convert(Document domDocument)`
Translates a DOM `org.w3c.dom.Document` object into an equivalent `nu.xom.Document` object.
`static Document`
DOMConverter.`convert(Document domDocument, NodeFactory factory)`
Translates a DOM `org.w3c.dom.Document` object into an equivalent `nu.xom.Document` object as controlled by a factory.
Methods in nu.xom.converters with parameters of type Document
Modifier and Type
Method
Description
`static Document`
DOMConverter.`convert(Document document, DOMImplementation impl)`
Translates a XOM `nu.xom.Document` object into an equivalent `org.w3c.dom.Document` object.
`void`
SAXConverter.`convert(Document doc)`
Feed a document through this converter.

## Uses of Document in nu.xom.tests

Methods in nu.xom.tests with parameters of type Document
Modifier and Type
Method
Description
`static void`
XOMTestCase.`assertEquals(String message, Document expected, Document actual)`
Asserts that two document nodes are equal.
`static void`
XOMTestCase.`assertEquals(Document expected, Document actual)`
Asserts that two document nodes are equal.

## Uses of Document in nu.xom.xinclude

Methods in nu.xom.xinclude that return Document
Modifier and Type
Method
Description
`static Document`
XIncluder.`resolve(Document in)`
Returns a copy of the document in which all `xinclude:include` elements have been replaced by their referenced content.
`static Document`
XIncluder.`resolve(Document in, Builder builder)`
Returns a copy of the document in which all `xinclude:include` elements have been replaced by their referenced content as loaded by the builder.
Methods in nu.xom.xinclude with parameters of type Document
Modifier and Type
Method
Description
`static Document`
XIncluder.`resolve(Document in)`
Returns a copy of the document in which all `xinclude:include` elements have been replaced by their referenced content.
`static Document`
XIncluder.`resolve(Document in, Builder builder)`
Returns a copy of the document in which all `xinclude:include` elements have been replaced by their referenced content as loaded by the builder.
`static void`
XIncluder.`resolveInPlace(Document in)`
Modifies a document by replacing all `xinclude:include` elements by their referenced content.
`static void`
XIncluder.`resolveInPlace(Document in, Builder builder)`
Modifies a document by replacing all `xinclude:include` elements with their referenced content as loaded by the builder.

## Uses of Document in nu.xom.xslt

Methods in nu.xom.xslt that return Document
Modifier and Type
Method
Description
`static Document`
XSLTransform.`toDocument(Nodes nodes)`
Builds a `Document` object from a `Nodes` object.
Methods in nu.xom.xslt with parameters of type Document
Modifier and Type
Method
Description
`Nodes`
XSLTransform.`transform(Document in)`
Creates a new `Nodes` from the input `Document` by applying this object's stylesheet.
Constructors in nu.xom.xslt with parameters of type Document
Modifier
Constructor
Description
``
`XSLTransform(Document stylesheet)`
Creates a new `XSLTransform` by reading the stylesheet from the supplied document.
``
`XSLTransform(Document stylesheet, NodeFactory factory)`
Creates a new `XSLTransform` by reading the stylesheet from the supplied document.