public class EcmsdkXMLHelper extends Object
| Constructor and Description |
|---|
EcmsdkXMLHelper() |
| Modifier and Type | Method and Description |
|---|---|
static Document |
createDOM(File file,
boolean validate,
boolean ignoringWhitespace)
Wrapper for createDocument from file
|
static Document |
createDOM(File file,
boolean validate,
boolean ignoringWhitespace,
Locale locale,
String characterEncoding)
Creates the DOM object from a Reader, using the Oracle DOM Parser.
|
static Document |
createDOM(InputStream stream,
boolean validate,
boolean ignoringWhitespace)
Wrapper mthod for create document
|
static Document |
createDOM(InputStream stream,
boolean validate,
boolean ignoringWhitespace,
Locale locale,
String characterEncoding)
Creates the DOM object from an InputStream, using the Oracle DOM Parser.
|
static Document |
createDOM(Reader reader,
boolean validate,
boolean ignoringWhitespace) |
static Document |
createDOM(Reader reader,
boolean validate,
boolean ignoringWhitespace,
Locale locale,
String characterEncoding)
Creates the DOM object from a Reader, using the Oracle DOM Parser.
|
static Document |
createEmptyDocument()
Create empty document
|
static Document |
createXMLDocument(InputStream input,
boolean validating,
boolean ignoringWhitespace)
Create XML Document
|
static DocumentBuilderFactory |
getNewDocumentBuilderFactory(boolean validate)
Get new DocumentBuilderFactory
setXIncludeAware, setExpandEntityReferences and setIgnoringElementContentWhitespace are automatically set to false
|
static String |
innerXml(Node node)
Print inner node to text
|
static ByteArrayOutputStream |
printXMLDocument(Document document,
String encoding)
print xml document
|
static void |
validateName(String nameToValidate)
validate name
|
public static DocumentBuilderFactory getNewDocumentBuilderFactory(boolean validate)
validate - : if true, the document is validatedpublic static Document createEmptyDocument() throws IfsException
IOCExceptionIfsExceptionpublic static Document createXMLDocument(InputStream input, boolean validating, boolean ignoringWhitespace) throws IfsException
input - Input streamvalidating - validateignoringWhitespace - ignore the white spaceIfsExceptionpublic static Document createDOM(InputStream stream, boolean validate, boolean ignoringWhitespace, Locale locale, String characterEncoding) throws IfsException
stream - the InputStream representing the XML documentvalidate - boolean indicating whether the DOM parser should be
used in validating or non-validating modeIfsException - thrown if the operation failspublic static Document createDOM(InputStream stream, boolean validate, boolean ignoringWhitespace) throws IfsException
stream - validate - ignoringWhitespace - IfsExceptionpublic static Document createDOM(Reader reader, boolean validate, boolean ignoringWhitespace, Locale locale, String characterEncoding) throws IfsException
reader - the Reader representing the XML documentvalidate - boolean indicating whether the DOM parser should be
used in validating or non-validating modeIfsException - thrown if the operation failspublic static Document createDOM(Reader reader, boolean validate, boolean ignoringWhitespace) throws IfsException
IfsExceptionpublic static Document createDOM(File file, boolean validate, boolean ignoringWhitespace, Locale locale, String characterEncoding) throws IfsException
reader - the Reader representing the XML documentvalidate - boolean indicating whether the DOM parser should be
used in validating or non-validating modeIfsException - thrown if the operation failspublic static Document createDOM(File file, boolean validate, boolean ignoringWhitespace) throws IfsException
file - validate - ignoringWhitespace - IfsExceptionpublic static String innerXml(Node node)
node - public static void validateName(String nameToValidate) throws DOMException
nameToValidate - DOMExceptionpublic static ByteArrayOutputStream printXMLDocument(Document document, String encoding) throws IfsException
document - IfsExceptionCopyright © 2025. All rights reserved.