Examples of XMLDiff


Examples of org.castor.xmlctf.xmldiff.XMLDiff

     * @throws java.io.IOException if an error occurs reading either XML
     *             document
     */
    public static int compare(final String document1, final String document2)
                                                         throws java.io.IOException {
        XMLDiff diff = new XMLDiff(document1, document2);
        return diff.compare();
    }
View Full Code Here

Examples of org.castor.xmlctf.xmldiff.XMLDiff

        // 2. load expected schema
        URL expectedUrl = this.getClass().getResource(expected);
        File expectedSchemaFile = new File(expectedUrl.toURI());

        // 3. compare using org.castor.xmlctf.xmldiff.XMLDiff
        XMLDiff diff = new XMLDiff(targetedOutput.getAbsolutePath(), expectedSchemaFile.getAbsolutePath());
        int result = diff.compare();
        TestResult testResult = result == 0 ? TestResult.IDENTICAL : TestResult.DIFFERENCE;

        // 4. delete temporary file
        targetedOutput.delete();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.