public interface CustomXmlDataStorage
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
cachedXPathGetString(java.lang.String xpath,
java.lang.String prefixMappings)
(Unless you are using Saxon as your XPath implementation (XPathFactoryUtil.setxPathFactory))
this uses org.apache.xpath.CachedXPathAPI for better performance, since Apache's old XPathAPI class,
have the drawback of instantiating a new XPathContext
(and thus building a new DTMManager, and new DTMs) each time it was called.
|
void |
discardCacheXPathObject()
Use this to null out the org.apache.xpath.CachedXPathAPI object, which you should do
if you've changed your source document, or want to reclaim memory.
|
CustomXmlDataStorage |
factory()
Create this object.
|
org.w3c.dom.Document |
getDocument()
Write the contents of this object to the org.w3c.dom.Document
|
java.lang.String |
getXML()
Get the XML as a String.
|
void |
setDocument(org.w3c.dom.Document doc) |
void |
setDocument(java.io.InputStream is)
Set the contents of this object from the input stream
|
boolean |
setNodeValueAtXPath(java.lang.String xpath,
java.lang.String value,
java.lang.String prefixMappings) |
void |
writeDocument(java.io.OutputStream os)
Write the contents of this object to the output stream
|
java.util.List<org.w3c.dom.Node> |
xpathGetNodes(java.lang.String xpathString,
java.lang.String prefixMappings) |
java.lang.String |
xpathGetString(java.lang.String xpath,
java.lang.String prefixMappings)
Get the data pointed to by the xpath.
|
CustomXmlDataStorage factory()
java.lang.String xpathGetString(java.lang.String xpath,
java.lang.String prefixMappings)
throws Docx4JException
xpath - Docx4JExceptionjava.lang.String cachedXPathGetString(java.lang.String xpath,
java.lang.String prefixMappings)
throws Docx4JException
xpath - prefixMappings - Docx4JExceptiondiscardCacheXPathObjectvoid discardCacheXPathObject()
java.util.List<org.w3c.dom.Node> xpathGetNodes(java.lang.String xpathString,
java.lang.String prefixMappings)
boolean setNodeValueAtXPath(java.lang.String xpath,
java.lang.String value,
java.lang.String prefixMappings)
throws Docx4JException
Docx4JExceptionvoid setDocument(java.io.InputStream is)
throws Docx4JException
is - Docx4JExceptionvoid setDocument(org.w3c.dom.Document doc)
throws Docx4JException
Docx4JExceptionvoid writeDocument(java.io.OutputStream os)
throws Docx4JException
os - Docx4JExceptionorg.w3c.dom.Document getDocument()
throws Docx4JException
os - Docx4JExceptionjava.lang.String getXML()
throws Docx4JException
Docx4JExceptionCopyright © 2007–2023. All rights reserved.