|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Raw inline data in leaf content.
Currently, this interface returns the raw inline data as a DOM node list. That will be awkward for some implementations, especially for any future implementations not based on a DOM tree. Possible future alternatives include returning all of the inline data as a string, and providing mechanisms for decoding encoded inline data (i.e. base64 and similar) to produce binary objects.
Method Summary | |
org.w3c.dom.NodeList |
getDOMNodes()
Get the inline data as a list of DOM nodes. |
String |
getText()
Get the inline data as plain text, ignoring any XML markup. |
String |
getXMLString()
Get the inline data as a fragment of XML markup. |
Methods inherited from interface org.newsml.toolkit.BaseNode |
getChild, getChild, getChild, getChild, getChildCount, getChildCount, getParent, getPath, getSession, getXMLName, getXPath, removeSelf, toXML, toXML, writeXML, writeXML |
Methods inherited from interface org.newsml.toolkit.IdNode |
getDuid, getEuid |
Method Detail |
public org.w3c.dom.NodeList getDOMNodes()
This method may return more than one top-level node, possibly accompanied by text and whitespace.
public String getText()
This method is most useful when the inline content is base64-encoded binary data or something similar, where XML markup is not relevant and XML character escaping is undesirable.
public String getXMLString()
This method is most useful when the inline content is NITF or XHTML XML markup or something similar, where the markup needs to be preserved for parsing by another software component. Note that the string is *not* guaranteed to be a well-formed XML document, since it may contain more than one top-level element.
BaseNode.toXML(boolean)
,
BaseNode.writeXML(java.io.Writer, boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |