• Main Page
  • Related Pages
  • Namespaces
  • Data Structures
  • Files
  • File List
  • Globals

onlinemonitor/spadicmonitor/TSpadicAnalysis.cxx (r4864/r3724)

Go to the documentation of this file.
00001 
00002 
00003 #include "TSpadicAnalysis.h"
00004 
00005 #include <stdlib.h>
00006 
00007 #include "Go4EventServer.h"
00008 #include "TGo4StepFactory.h"
00009 #include "TGo4AnalysisStep.h"
00010 #include "TGo4Version.h"
00011 #include "TGo4Log.h"
00012 
00013 
00014 
00015 //***********************************************************
00016 TSpadicAnalysis::TSpadicAnalysis()
00017 {
00018 }
00019 //***********************************************************
00020 
00021 // this constructor is called by go4analysis executable
00022 TSpadicAnalysis::TSpadicAnalysis(int argc, char** argv) :
00023    TGo4Analysis(argc, argv)
00024 {
00025    if (!TGo4Version::CheckVersion(__GO4BUILDVERSION__)) {
00026       TGo4Log::Error("Go4 version mismatch");
00027       exit(-1);
00028    }
00029 
00030    TGo4Log::Info("Create TSpadicAnalysis name: %s", argv[0]);
00031 
00032    TGo4StepFactory* factory = new TGo4StepFactory("Factory");
00033    factory->DefEventProcessor("SpadicProc","TSpadicProc");// object name, class name
00034    factory->DefOutputEvent("SPADIC","TSpadicEvent"); // object name, class name
00035    factory->DefUserEventSource("TSpadicSource"); // object name, class name
00036 
00037            
00038    TGo4EventSourceParameter* sourcepar = new TGo4MbsFileParameter(Form("%s/data/test.lmd",getenv("GO4SYS")));
00039    TGo4FileStoreParameter* storepar = new TGo4FileStoreParameter(Form("%sOutput", argv[0]));
00040    storepar->SetOverwriteMode(kTRUE);
00041 
00042    TGo4AnalysisStep* step = new TGo4AnalysisStep("Spadic", factory, sourcepar, storepar);
00043 
00044    step->SetSourceEnabled(kTRUE);
00045    step->SetStoreEnabled(kFALSE);
00046    step->SetProcessEnabled(kTRUE);
00047    step->SetErrorStopEnabled(kTRUE);
00048 
00049    // Now the first analysis step is set up.
00050    // Other steps could be created here
00051    AddAnalysisStep(step);
00052 
00053    // uncomment following line to define custom passwords for analysis server
00054    // DefineServerPasswords("CernOct11admin", "CernOct11ctrl", "CernOct11view");
00055 
00056 }
00057 
00058 //***********************************************************
00059 TSpadicAnalysis::~TSpadicAnalysis()
00060 {
00061    TGo4Log::Info("TSpadicAnalysis: Delete instance");
00062 }
00063 

Generated on Tue Dec 10 2013 04:52:23 for ROCsoft by  doxygen 1.7.1