#include "RunVP1Light/VP1LightRun.h"
#include <QSettings>
#include <QString>
#include <QDir>
#include <QDebug>
#include <QCommandLineParser>
#include <iostream>
#include <stdlib.h>
#include <fstream>
Go to the source code of this file.
|
int | main (int argc, char **argv) |
|
◆ main()
int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 23 of file graphics/VP1/RunVP1Light/src/main.cxx.
33 QCommandLineOption databaseDirectoryOption(QStringList() <<
"d" <<
"database-directory",
"Use geometry database <file>.",
"default");
34 parser.addOption(databaseDirectoryOption);
37 QCommandLineOption AODDirectoryOption(QStringList() <<
"x" <<
"xaod-directory",
"Use xAOD file <file>.",
"default");
38 parser.addOption(AODDirectoryOption);
41 QCommandLineOption helpOption(QStringList() <<
"h" <<
"help",
"Show help.");
42 parser.addOption(helpOption);
47 bool helpIsSet =
parser.isSet(helpOption);
48 bool dbIsSet =
parser.isSet(databaseDirectoryOption);
49 bool AODIsSet =
parser.isSet(AODDirectoryOption);
50 QString dbDir =
parser.value(databaseDirectoryOption);
51 QString aodDir =
parser.value(AODDirectoryOption);
57 qInfo() <<
" vp1light [options]";
59 qInfo() <<
"Add path to geometry database or AOD file as options. Alternatively they can be set inside VP1Light.";
61 qInfo() <<
"Options:";
62 qInfo() <<
" -h, --help = Show help.";
63 qInfo() <<
" -d, --database-directory <path-to-DB> = Specify geometry database file.";
64 qInfo() <<
" -x, --xaod-directory <path-to-xAOD> = Specify xAOD file.";
69 QSettings settings(
"ATLAS",
"VP1Light");
71 settings.setValue(
"db/path", dbDir);
72 settings.setValue(
"db/dbByEnv",
"1");
75 settings.setValue(
"db/dbByEnv",
"");
78 settings.setValue(
"aod/path", aodDir);
79 settings.setValue(
"aod/aodByEnv",
"1");
82 settings.setValue(
"aod/aodByEnv",
"");
86 if(settings.value(
"ExpertSettings/notFirstStart").toString().isEmpty()){
87 settings.setValue(
"ExpertSettings/notFirstStart",
"1");
88 settings.setValue(
"ExpertSettings/enableExpertSettings",
"");
94 vp1light.initialize();
95 while ( vp1light.execute());