source: trunk/test/ExRootMain.cpp@ 22

Last change on this file since 22 was 2, checked in by Pavel Demin, 16 years ago

first commit

File size: 642 bytes
Line 
1
2#include "ExRootAnalysis/ExRootAnalysis.h"
3
4#include "TROOT.h"
5#include "TApplication.h"
6
7#include <iostream>
8
9using namespace std;
10
11int main(int argc, char *argv[])
12{
13 char *appName = "ExRootMain";
14
15 if(argc != 2)
16 {
17 cout << " Usage: " << appName << " input_file" << endl;
18 cout << " input_file - configuration file in Tcl format." << endl;
19 return 1;
20 }
21
22 gROOT->SetBatch();
23
24 int appargc = 1;
25 char *appargv[] = {appName};
26 TApplication app(appName, &appargc, appargv);
27
28 TString inputFile(argv[1]);
29
30 ExRootAnalysis test;
31 test.SetTclFileName(inputFile);
32 test.InitTask();
33 test.Loop();
34 test.FinishTask();
35}
Note: See TracBrowser for help on using the repository browser.