Package co.ecg.alpaca.commons.formatting
Class XMLUtils
java.lang.Object
co.ecg.alpaca.commons.formatting.XMLUtils
XML Utility Class for the Alpaca Library. These utilities are used in both
the generation process and the toolkit.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic DocumentBuilder
Gets the Document Builder Factorystatic Transformer
Gets the XML Transformerstatic XPath
getXPath()
Gets the XPath for the library.static String
maskXMLStringForLog
(String string) static String
transformDOMToXML
(Node node) Transformer operation to convert DOM node to an XML Stringstatic String
transformStringToXML
(String string) Transformer operation to format a String of any style to an XML String.
-
Constructor Details
-
XMLUtils
public XMLUtils()
-
-
Method Details
-
getDocumentBuilder
Gets the Document Builder Factory- Returns:
- The DocumentBuilder Object
-
getXMLTransformer
Gets the XML Transformer- Returns:
- The XML Transformer Object
-
getXPath
Gets the XPath for the library. The XPath is pre-filled with information regarding the OCI schema.- Returns:
- The Alpaca XPath
-
transformDOMToXML
Transformer operation to convert DOM node to an XML String- Parameters:
node
- The Node to transform.- Returns:
- Returns the XML string for the DOM node.
-
transformStringToXML
Transformer operation to format a String of any style to an XML String. This requires the given string to be XML valid or it will fail.- Parameters:
string
- The String to format.- Returns:
- Returns the XML formatted String.
-
maskXMLStringForLog
-