BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnFDContFact.cxx
Go to the documentation of this file.
1#include "BmnFDContFact.h"
2
3#include "BmnFDGeoPar.h"
4#include "FairParAsciiFileIo.h"
5#include "FairParRootFileIo.h"
6#include "FairRuntimeDb.h"
7
8#include <iomanip>
9#include <iostream>
10
11using namespace std;
12
14
16{
17 // Constructor (called when the library is loaded)
18 fName = "BmnFDContFact";
19 fTitle = "Factory for parameter containers in libFD";
21 FairRuntimeDb::instance()->addContFactory(this);
22}
23
25{
26 /** Creates the Container objects with all accepted contexts and adds them to
27 * the list of containers for the FD library.*/
28
29 FairContainer* t = new FairContainer("BmnFDGeoPar", "FD Geometry Parameters", "FDDefaultContext");
30 t->addContext("FDNonDefaultContext");
31
32 containers->Add(t);
33
34 // p->print();
35}
36
38{
39 /** Calls the constructor of the corresponding parameter container.
40 * For an actual context, which is not an empty string and not the default context
41 * of this container, the name is concatinated with the context. */
42 const char* name = c->GetName();
43 FairParSet* t = NULL;
44 if (strcmp(name, "BmnFDGeoPar") == 0) {
45 t = new BmnFDGeoPar(c->getConcatName().Data(), c->GetTitle(), c->getContext());
46 }
47 return t;
48}
static BmnFDContFact gBmnBD1ContFact
void setAllContainers()
FairParSet * createContainer(FairContainer *)
Definition json.hpp:4446