FairRoot/PandaRoot
PndAnaContFact.cxx
Go to the documentation of this file.
1 //
3 // PndAnaContFact
4 //
5 // Factory for the parameter containers in libAnalysisTools
6 //
8 
9 //using namespace std;
10 #include "PndAnaContFact.h"
11 #include "PndAnaSelectorPar.h"
12 #include "FairRuntimeDb.h"
13 #include "FairParRootFileIo.h"
14 #include "FairParAsciiFileIo.h"
15 #include "TList.h"
16 #include "TObjString.h"
17 #include <iostream>
18 #include <iomanip>
19 
21 
23 
25 {
26  // Constructor (called when the library is loaded)
27  fName="PndAnaContFact";
28  fTitle="Factory for parameter containers in analysis tools";
30  FairRuntimeDb::instance()->addContFactory(this);
31 }
33 {
34 }
35 
36 
38 {
42 // FairContainer* p= new FairContainer("ANAPidSelectionFlux","Flux weights", "TestDefaultContext");
43 // p->addContext("TestNonDefaultContext");
44 // fSelectParNames->Add(new TObjString(p->GetName()));
45 // containers->Add(p);
46 
47  FairContainer* p2 = new FairContainer("ANAPidSelections","PID selctrion criteria parameters", "TestDefaultContext");
48  p2->addContext("TestNonDefaultContext");
49  containers->Add(p2);
50 
51 }
52 
53 FairParSet* PndAnaContFact::createContainer(FairContainer* c)
54 {
58  const char* name=c->GetName();
59  FairParSet* p=NULL;
60 
61 // if (strcmp(name,"ANAPidSelectionFlux")==0) {
62 // p=new PndAnaSelectorPar(c->getConcatName().Data(),c->GetTitle(),c->getContext());
63 // }
64 
65  if (strcmp(name,"ANAPidSelections")==0) {
66  p=new PndAnaSelectorPar(c->getConcatName().Data(),c->GetTitle(),c->getContext());
67  }
68 
69 
70  return p;
71 }
Double_t p
Definition: anasim.C:58
FairParSet * createContainer(FairContainer *c)
static PndAnaContFact gPndAnaContFact
TString name
TPad * p2
Definition: hist-t7.C:117
ClassImp(PndAnaContFact)