XPathLister - Bulk XPath Analysis of XML documents
XPathLister counts elements and attributes in a set of xml documents. It can recursively process multiple directories, analize all xml documents found and provide a report of each possible XPaths that are found and
their frequency of occurance. This comes handy when you are presented with a set of xml files but left without any DTD / XML Schema. How do you know what the XML looks like? How do you start developing an XML schema
if you need one? XPathLister provides you with a summary of all elements and attributes that occur in the XML files and their frequencies so that you can comprehend the full set of XML tags that can appear, and
whether they are optional or required, and perhaps cardinality too.
XpathLister.exe -dir C:\dirwithxmlfiles\subdir -r
XPathLister counts the number of elements and attributes that appear in a set of XML files.
XPathLister helps to get an idea about the structure of XML files whose XML schema/DTD is not
known. Output is a list of XPath like expressions and their frequency of occurance in the XML documents that were scanned.
-file filename an xml filename or file name pattern such as *.xml to process. Default is *.xml.
-dir dirname a directory name
that contains XML files to process. Default is current directory.
-r recursively process sub directories.
Below example shows a quick pass over Eclipse feature directories to scan for feature.xml files:
This 1 sec run gives us a quick idea about the structure of feature.xml files that Eclipse uses.
The resulting output is much easier to read compared to a DTD or an XML Schema.