Package com.mycila.xmltool
Class XMLDocBuilder
java.lang.Object
com.mycila.xmltool.XMLDocBuilder
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddDefaultNamespace
(String defaultNamespaceURI) Set the default namespace to use in the document declaration.addNamespace
(String prefix, String namespaceURI) Add a namespace to the document that will be createdCreate a root node for this XML documentprivate static void
private static XMLTag
create
(XMLDocDefinition def) (package private) static XMLTag
(package private) static XMLTag
(package private) static XMLTag
from
(InputStream is, boolean ignoreNamespaces) (package private) static XMLTag
(package private) static XMLTag
(package private) static XMLTag
(package private) static XMLTag
(package private) static XMLTag
(package private) static XMLTag
from
(InputSource source, boolean ignoreNamespaces) (package private) static XMLTag
fromCurrentTag
(XMLTag tag, boolean ignoreNamespaces) private static boolean
needsNormalization
(String name) (package private) static XMLDocBuilder
newDocument
(boolean ignoreNamespaces) private static DocumentBuilder
newDocumentBuilder
(boolean ignoreNamespaces)
-
Field Details
-
definition
-
-
Constructor Details
-
XMLDocBuilder
-
-
Method Details
-
addNamespace
Add a namespace to the document that will be created- Parameters:
prefix
- The prefix of the namespacenamespaceURI
- The URI of the namespace- Returns:
- this
-
addDefaultNamespace
Set the default namespace to use in the document declaration. I.e.<html xmlns="http://www.w3.org/1999/xhtml">
- Parameters:
defaultNamespaceURI
- URI to use as default when tags are not prefixed- Returns:
- this
-
addRoot
Create a root node for this XML document- Parameters:
tagName
- Name of the element- Returns:
- XMLDoc instance to build and navigate in the document
-
create
-
needsNormalization
-
newDocument
-
from
-
from
-
from
-
from
-
from
-
from
-
from
-
from
-
fromCurrentTag
-
from
-
close
-
newDocumentBuilder
-