User`s guide

How to Compare XML Files
9-5
From the Comparison Tool
To compare files using the Comparison Tool, from the MATLAB Toolstrip, in the File
section, select the Compare button. In the dialog box select files to compare.
If the files you select to compare are XML files and you select an XML comparison, the
XML comparison tool performs a Chawathe analysis of the XML files, and generates an
report.
From the Command Line
To compare XML files from the command line, enter
visdiff(filename1, filename2)
where filename1 and filename1 are XML files. This XML comparison functionality is
an extension to the MATLAB visdiff function.
Change Comparison Type
If you specify two XML files to compare using either the Current Folder Browser or
the visdiff function, then the Comparison Tool automatically performs the default
comparison type, XML text comparison.
To change comparison type, either create a new comparison from the Comparison Tool,
or use the Compare Against option from the Current Folder browser. You can change
comparison type in the Select Files or Folders for Comparison dialog box. If you want
the MATLAB text differences report for XML files, change the comparison type to Text
comparison in the dialog before clicking Compare.
XML Comparison Examples
For an example with instructions, see mlxml_testplan.
See Also
For an overview, see “Compare XML Files” on page 9-2.
For explanations on how to use and understand the report and the XML comparison
functionality, see “Explore the XML Comparison Report” on page 9-6