FairRoot/PandaRoot
PndFtofContFact.cxx
Go to the documentation of this file.
1 //
3 // CbmHypContFact
4 //
5 // Factory for the parameter containers in libHyp
6 //
7 //
8 //
10 
11 #include "PndFtofContFact.h"
12 #include "FairRuntimeDb.h"
13 #include "iostream"
14 #include "FairParRootFileIo.h"
15 #include "FairParAsciiFileIo.h"
16 #include "PndGeoFtofPar.h"
17 #include <iostream>
18 #include <iomanip>
19 
21 
23 
25  // Constructor (called when the library is loaded)
26  fName="PndFtofContFact";
27  fTitle="Factory for parameter containers in libFtof";
28  setAllContainers();
29  FairRuntimeDb::instance()->addContFactory(this);
30 }
31 
36  FairContainer* p= new FairContainer("PndGeoFtofPar",
37  "tof Geometry Parameters",
38  "TestDefaultContext");
39  p->addContext("TestNonDefaultContext");
40 
41  containers->Add(p);
42 }
43 
44 FairParSet* PndFtofContFact::createContainer(FairContainer* c) {
48  const char* name=c->GetName();
49  FairParSet* p=NULL;
50  if (strcmp(name,"PndGeoFtofPar")==0) {
51  p=new PndGeoFtofPar(c->getConcatName().Data(),c->GetTitle(),c->getContext());
52  }
53  return p;
54 }
Double_t p
Definition: anasim.C:58
FairParSet * createContainer(FairContainer *)
TString name
static PndFtofContFact gPndFtofContFact
ClassImp(PndAnaContFact)