Simple XML parser application.

[February 2004]

Description: A basic XML parser that can parse just elements, no attributes and can be queried for basic values.

This was a demo application I did for an interview which was designed to demonstrate well defined objects / interfaces, Design patterns, Test Driven Development, Code refactoring, and no code duplication. I think it does.. :)

Notes:As this parser is not designed to handle attributes, any attributes within the XML tags will be considered as the name of the tag, and possible cause the parser to interpret the XML as badly-formed. I may add the ability to add attributes in the future.

Requires: JDK1.4.1

Useage:

Simple XML Parser Application.

Useage:

  run [input file] [tag to search for]
      [assume "tag to search for" is a regular expression (optional) 
       - "true" or "false"]

Directory structure: run.bat - Runs the application from the jar.
build/ - Ant build script [I used ant 1.6.1, older versions should be fine]
docs/ - Generated Javadocs
lib/ - Jar files (Junit and generated jar file)
src/ - Source Code
testsuite/ - Test hierarchy. (The tests can be run by calling "ant test" in the build dir.)
- /src/ - Test source files
- /testfiles/ - XML documents used by Junit tests


Return to project page