java.lang.Object
com.tectonica.xmlchunk.XmlUtil
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
XmlUtil
public XmlUtil()
-
-
Method Details
-
elementToString
Transforms a DOMElementinto an XML text- Parameters:
elem- the element to transform into textstrip- if true, removes the containing tag of the XML node- Returns:
- an XML text representation of the given element
-
unescape
Transforms an escaped XML into the original, "un-escaped" value (for example turn <Hello> into <Hello>).If the input contains no
&character it is returned as-is (preserving any actual XML markup). Standard entity references (<,>,&,',") and numeric character references (&#NNN;/&#xHHH;) are decoded; unknown named entities are left unchanged.- Parameters:
escaped- the (possibly escaped) XML string- Returns:
- the un-escaped string
-