QwAnalysis
QwRoot.cc
Go to the documentation of this file.
1 /*------------------------------------------------------------------------*//*!
2 
3  \file QwRoot.cc
4 
5  \ingroup QwAnalysis
6 
7  \brief ROOT wrapper with Qweak functionality
8 
9 *//*-------------------------------------------------------------------------*/
10 
11 // ROOT headers
12 #include <TSystem.h>
13 #include <TROOT.h>
14 #include <TString.h>
15 
16 // Qweak headers
17 #include "QwRint.h"
18 #include "QwOptions.h"
19 
20 int main(int argc, char** argv)
21 {
22  // Start Qw-Root command prompt
23  QwRint* qwrint = new QwRint("Qweak-Root Analyzer", &argc, argv);
24  // Set some paths
25  TString path = getenv_safe_TString("QWANALYSIS");
26  gROOT->ProcessLine(".include " + path + "/Analysis/include");
27  gROOT->ProcessLine(".include " + path + "/Parity/include");
28  gROOT->ProcessLine(".include " + path + "/Tracking/include");
29  gROOT->ProcessLine("gSystem->Load(\"libCint.so\");");
30  // Run the interface
31  qwrint->Run();
32  // Delete object
33  delete qwrint;
34 }
const TString getenv_safe_TString(const char *name)
Definition: QwOptions.h:40
A ROOT command line interface.
Definition: QwRint.h:25
An options class which parses command line, config file and environment.
int main(int argc, char **argv)
Definition: QwRoot.cc:20