DOMjudge supports the ICPC validator interface standard, which can be found at: http://www.ecs.csus.edu/pc2/doc/valistandard.html
The invocation code (judge/test_solution.h
) adheres to the
invocation interface. It passes as a 5th optional parameter to the
validator program the filename in which it expects a difference output
between the program and jury output (parameters 2 and 3 respectively).
Parsing of the result XML file (in the result interface) is done with the `xsltproc' program, which is part of the GNOME libxslt package. The exitcode of the validator program should be zero, otherwise an internal error is generated.
DOMjudge currently has two validator scripts: judge/compare
and judge/compare_program.sh
. The first does a compare with a
plain diff, the second script calls an external program for checking
(e.g. judge/check_float
for comparison of floating point
results). When passed a 5th parameter, this is interpreted as a
filename to which these scripts will write a comparison of the program
and jury output. Both scripts also generate XML compliant output,
which is written to the result file specified in parameter 4 and fully
complies with the validator standard.