Uses of Class
eu.maveniverse.domtrip.Document
Packages that use Document
Package
Description
DomTrip - A lossless XML processing library for Java.
-
Uses of Document in eu.maveniverse.domtrip
Methods in eu.maveniverse.domtrip that return DocumentModifier and TypeMethodDescriptionDocument.bom(boolean bom) Sets whether a Byte Order Mark (BOM) should be written when serializing to an OutputStream.Document.clone()Deprecated.Document.copy()Creates a deep copy of this node.Sets the DOCTYPE declaration for this document.Editor.document()Gets the current XML document being edited.Node.document()Gets the Document that contains this node.Set the document's character encoding used for serialization.static DocumentCreates a minimal document with just a root element (no XML declaration).static DocumentDocument.of()Creates an empty document with default settings.static DocumentDocument.of(InputStream inputStream) Creates a document by parsing XML from an InputStream with automatic encoding detection.static DocumentDocument.of(InputStream inputStream, String defaultEncoding) Creates a document by parsing XML from an InputStream with encoding detection and fallback.static DocumentDocument.of(InputStream inputStream, Charset defaultCharset) Creates a document by parsing XML from an InputStream with encoding detection and fallback.static DocumentCreates a document by parsing the provided XML string.static DocumentCreates a document by parsing XML from a file path with automatic encoding detection.Document.parent(ContainerNode parent) Sets the parent container node of this node.Parser.parse(InputStream inputStream) Parses XML from an InputStream with automatic encoding detection.Parser.parse(InputStream inputStream, String defaultEncoding) Parses XML from an InputStream with encoding detection and fallback.Parser.parse(InputStream inputStream, Charset defaultCharset) Parses XML from an InputStream with encoding detection and fallback.Parses an XML string into a lossless XML document tree.Sets the root element of this document.Document.standalone(boolean standalone) Sets the standalone flag for this document.Set the XML version of this document.static DocumentDocument.withDoctype(String version, String encoding, String doctype) Creates a document with XML declaration and DOCTYPE.static DocumentDocument.withRootElement(String rootElementName) Creates a document with a root element and XML declaration.Document.withXmlDeclaration()Generates and sets an XML declaration based on current document settings.static DocumentDocument.withXmlDeclaration(String version, String encoding) Creates a document with XML declaration.static DocumentDocument.withXmlDeclaration(String version, String encoding, boolean standalone) Creates a document with XML declaration and standalone attribute.Document.xmlDeclaration(String xmlDeclaration) Sets the XML declaration for this document.Methods in eu.maveniverse.domtrip with parameters of type DocumentModifier and TypeMethodDescriptionDiffResult.changesFor(XPathExpression xpath, Document doc) Returns changes affecting elements that match the given compiled XPath expression in the specified document.DiffResult.changesFor(String xpath, Document doc) Returns changes affecting elements that match the given XPath expression in the specified document.static EmptyElementStyleEmptyElementStyle.detectFromDocument(Document document) Detects the predominant empty element style used in a document.static DiffResultCompares two documents using default configuration (positional matching).static DiffResultXmlDiff.diff(Document before, Document after, DiffConfig config) Compares two documents using the given configuration.Serializes an XML document to string using this serializer's configuration.Serializer.serialize(Document document, DomTripConfig config) Serializes an XML document to string with custom configuration.voidSerializer.serialize(Document document, OutputStream outputStream) Serializes an XML document to an OutputStream using the document's encoding.voidSerializer.serialize(Document document, OutputStream outputStream, String encoding) Serializes an XML document to an OutputStream using the specified encoding.voidSerializer.serialize(Document document, OutputStream outputStream, Charset charset) Serializes an XML document to an OutputStream using the specified charset.DomTripConfig.withAutoDetectedEmptyElementStyle(Document document) Automatically detects and configures the empty element style based on existing empty elements in the provided document.Constructors in eu.maveniverse.domtrip with parameters of type DocumentModifierConstructorDescriptionCreates a new editor with an existing Document.Editor(Document document, DomTripConfig config) Creates a new editor with an existing Document and custom configuration. -
Uses of Document in eu.maveniverse.domtrip.sax
Methods in eu.maveniverse.domtrip.sax that return DocumentModifier and TypeMethodDescriptionDomTripXMLReader.getDocument()Returns the document backing this reader.Methods in eu.maveniverse.domtrip.sax with parameters of type DocumentModifier and TypeMethodDescriptionstatic DomTripSAXSourceCreates a new SAXSource backed by the given document.voidSAXOutputter.output(Document doc, ContentHandler handler) Emits SAX events for the given document to the specified content handler.voidSAXOutputter.output(Document doc, ContentHandler handler, LexicalHandler lexicalHandler) Emits SAX events for the given document to the specified content and lexical handlers.Constructors in eu.maveniverse.domtrip.sax with parameters of type DocumentModifierConstructorDescriptionDomTripXMLReader(Document document) Creates a new XMLReader that reads from the given document. -
Uses of Document in eu.maveniverse.domtrip.stax
Methods in eu.maveniverse.domtrip.stax with parameters of type DocumentModifier and TypeMethodDescriptionstatic DomTripStAXSourceCreates a new StAXSource backed by the given document.Constructors in eu.maveniverse.domtrip.stax with parameters of type DocumentModifierConstructorDescriptionDomTripStreamReader(Document document) Creates a new StAX reader for the given document.
Document.copy()instead.