PDFUnit provides utility programs to extract several parts of a PDF document into separate files, mostly XML, which can then be used in tests. The following list gives an overview of the available programs:
The utility programs generate files. Their names are derived from those of the input files. The following rules are used to avoid naming conflicts with existing files:
Generated file names start with an underscore.
The names have two suffices. The penultimate is
and the last one is the typical suffix for the kind of file type.
For example, when you extract bookmarks from
_bookmarks_foo.out.xml is created. Rename it
before using it in a test, because then it is no longer an output file.
The Windows batch scripts in the following chapters demonstrate how to start the programs. These scripts are part of the PDFUnit release, but you have to adapt most of their content to your environment anyway: you need to set the classpath, input file and output directory.
When you start a program without parameters or with incorrect parameters, PDFUnit shows a message detailing the corect command line parameters.
The utilities also run on Unix. Unix developers should easily translate the Windows scripts into shell scripts. If you need assistance, please contact us at: support[at]pdfunit.com.