java.lang.Object
de.hybris.platform.subscriptionfacades.util.XmlUtils

public class XmlUtils extends Object
Helper class for xml transformation
  • Method Details

    • applyTransformationResource

      public static String applyTransformationResource(String xml, String transformationResource)
      Removes all ignored nodes from the given xml
      Parameters:
      xml - the xml to process
      transformationResource - the transformation to apply (classpath resource)
      Returns:
      the processed xml (in case of errors the original xml is returned)
    • evaluateXPath

      public static final String evaluateXPath(String targetXml, String xPath)
      Parameters:
      targetXml - the XML to apply the XPath expression to
      xPath - the XPath expression to apply
      Returns:
      the result of XPath evaluation
    • transform

      protected static String transform(String targetXml, StreamSource source) throws TransformerFactoryConfigurationError
      Throws:
      TransformerFactoryConfigurationError