A simple command-line program that reads an SBML file and prints some statistics about it.
#include <iostream>
int
main (int argc, char* argv[])
{
if (argc != 2)
{
cout << endl << "Usage: readSBML filename" << endl << endl;
return 1;
}
const char* filename = argv[1];
#ifdef __BORLANDC__
unsigned long start, stop;
#else
unsigned long long start, stop;
#endif
start = getCurrentMillis();
stop = getCurrentMillis();
cout << endl;
cout << " filename: " << filename << endl;
cout << " file size: " << getFileSize(filename) << endl;
cout << " read time (ms): " << stop - start << endl;
cout << " validation error(s): " << errors << endl;
cout << endl;
delete document;
return errors;
}