Class Utilities


  • public class Utilities
    extends Object
    • Constructor Detail

      • Utilities

        public Utilities()
    • Method Detail

      • generateRDDocumentation

        public String generateRDDocumentation​(InputStream sourceStream)
        Generates human readable documentation out of RD file.
        Parameters:
        sourceStream - InputStream The source document (XML) as stream
        Returns:
        resulting HTHML document
        Throws:
        Exception
      • generateRDDocumentation

        public String generateRDDocumentation​(Document document)
        Parameters:
        document -
        Returns:
        Throws:
        Exception
      • makeTransform

        public String makeTransform​(InputStream sourceStream,
                                    String transform)
        Makes transformation for a file
        Parameters:
        sourceStream - InputStream The source document (XML) as stream
        transform - String String Path and name of the transformation file (XSLT)
        Returns:
        String result
        Throws:
        WrongFormatException
        Exception
      • makeTransform

        public String makeTransform​(Document document,
                                    String xsltPath)
        Makes transformation for DOM Document
        Parameters:
        document - DOM document document (XML) as DOM Document
        transform - String String Path and name of the transformation file (XSLT)
        Returns:
        String result
        Throws:
        WrongFormatException
        Exception
      • xmlToString

        public String xmlToString​(Node node)
                           throws Exception
        Prints out the XML structure as string
        Parameters:
        node - Node
        Returns:
        String
        Throws:
        Exception