#! /bin/sh if [ $# -ne 1 ] then echo " Usage: $0 output_file" echo " output_file - output file in HTML format." exit fi awk ' BEGIN { print "" print "" print "" print " " print " " print " root tree description" print " " print "" print "" print "

ROOT Tree Description

" print "

Description of all classes used to store output data.

" print "" print "" print "" print "" } function print_line(name, comment, even, end) { if(name != ""){ if(even) print "" else print "" print " " split(comment, a, "|"); print " " print " " print "" } } /^ *class /{ print_line(name, comment, even, 1); even = 0; name = ""; comment = ""; split($2, a, ":"); if(a[1] == "Candidate" || a[1] == "DelphesFactory;") next; print "" } /: public /{ if($4 == "TObject" || $4 == "SortableObject") next; name = sprintf("%s", $4, $4); split($2, a, ":"); comment = sprintf("%s inherits all %s parameters", a[1], $4); } /^ *[A-Za-z_]* [A-Za-z].*; \/\/ / { print_line(name, comment, even, 0); split($2, a, ";"); name = a[1]; split($0, a, "// "); comment = a[2]; even = !even; } /^ +\/\/ /{split($0, a, "// "); comment = comment" "a[2]} END { print_line(name, comment, even, 1); print "
ParameterDefinitionHow it was calculated
"name""a[1]""a[2]"
class "a[1]"
" print "" }' `dirname $0`/../classes/DelphesClasses.h > $1