R3BROOT
R3B analysis software
Loading...
Searching...
No Matches
R3BPassiveContFact.cxx
Go to the documentation of this file.
1
/******************************************************************************
2
* Copyright (C) 2019 GSI Helmholtzzentrum für Schwerionenforschung GmbH *
3
* Copyright (C) 2019-2025 Members of R3B Collaboration *
4
* *
5
* This software is distributed under the terms of the *
6
* GNU General Public Licence (GPL) version 3, *
7
* copied verbatim in the file "LICENSE". *
8
* *
9
* In applying this license GSI does not waive the privileges and immunities *
10
* granted to it by virtue of its status as an Intergovernmental Organization *
11
* or submit itself to any jurisdiction. *
12
******************************************************************************/
13
14
//*-- AUTHOR : Denis Bertini
15
//*-- Created : 21/06/2005
16
18
//
19
// R3BPassiveContFact
20
//
21
// Factory for the parameter containers in libPassive
22
//
24
25
#include "
R3BPassiveContFact.h
"
26
#include "
R3BGeoPassivePar.h
"
27
#include "R3BTGeoPar.h"
28
29
static
R3BPassiveContFact
gR3BPassiveContFact
;
30
31
R3BPassiveContFact::R3BPassiveContFact
()
32
{
33
// Constructor (called when the library is loaded)
34
fName =
"R3BPassiveContFact"
;
35
fTitle =
"Factory for parameter containers in libPassive"
;
36
setAllContainers();
37
FairRuntimeDb::instance()->addContFactory(
this
);
38
}
39
40
void
R3BPassiveContFact::setAllContainers()
41
{
44
45
FairContainer* p =
new
FairContainer(
"R3BGeoPassivePar"
,
"Passive Geometry Parameters"
,
"TestDefaultContext"
);
46
p->addContext(
"TestNonDefaultContext"
);
47
48
containers->Add(p);
49
50
FairContainer* p2 =
new
FairContainer(
"TargetGeoPar"
,
"Target geometry parameters"
,
"GeometryParameterContext"
);
51
p2->addContext(
"GeometryParameterContext"
);
52
containers->Add(p2);
53
}
54
55
FairParSet*
R3BPassiveContFact::createContainer
(FairContainer*
c
)
56
{
60
61
const
char
* name =
c
->GetName();
62
FairParSet* p = NULL;
63
if
(strcmp(name,
"R3BGeoPassivePar"
) == 0)
64
{
65
p =
new
R3BGeoPassivePar
(
c
->getConcatName().Data(),
c
->GetTitle(),
c
->getContext());
66
}
67
if
(strcmp(name,
"TargetGeoPar"
) == 0)
68
{
69
p =
new
R3BTGeoPar(
c
->getConcatName().Data(),
c
->GetTitle(),
c
->getContext());
70
}
71
return
p;
72
}
73
74
ClassImp
(
R3BPassiveContFact
);
R3BGeoPassivePar.h
c
static const Double_t c
Definition
R3BNeulandNeutron.cxx:18
gR3BPassiveContFact
static R3BPassiveContFact gR3BPassiveContFact
Definition
R3BPassiveContFact.cxx:29
ClassImp
ClassImp(R3BPassiveContFact)
R3BPassiveContFact.h
R3BGeoPassivePar
Definition
R3BGeoPassivePar.h:21
R3BPassiveContFact
Definition
R3BPassiveContFact.h:24
R3BPassiveContFact::R3BPassiveContFact
R3BPassiveContFact()
Definition
R3BPassiveContFact.cxx:31
R3BPassiveContFact::createContainer
FairParSet * createContainer(FairContainer *)
Definition
R3BPassiveContFact.cxx:55
passive
R3BPassiveContFact.cxx
Generated by
1.13.2