EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
FairBaseParSet.cxx
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file FairBaseParSet.cxx
1
// -------------------------------------------------------------------------
2
// ----- FairBaseParSet source file -----
3
// ----- Created 06/01/04 by M. Al/Turany -----
4
// -------------------------------------------------------------------------
5
6
#include "
FairBaseParSet.h
"
7
#include "
FairPrimaryGenerator.h
"
8
#include "
FairParamList.h
"
9
#include "TObjArray.h"
10
11
12
ClassImp
(
FairBaseParSet
)
13
14
FairBaseParSet
::
FairBaseParSet
(const
char
*
name
,const
char
*
title
,const
char
* context)
15
:
FairParGenericSet
(name,title,context),
16
fDetList(0),
17
fGeoNodes(new TObjArray()),
18
fPriGen(0),
19
fBeamMom(15),
20
fGeom(0),
21
fContNameList(new TObjArray())
22
{
23
24
25
}
26
27
28
FairBaseParSet::~FairBaseParSet
(
void
)
29
{
30
}
31
32
void
FairBaseParSet::clear
(
void
)
33
{
34
if
(
fPriGen
) {
delete
fPriGen
; }
35
if
(
fDetList
) {
delete
fDetList
; }
36
if
(
fGeoNodes
) {
delete
fGeoNodes
; }
37
if
(
fContNameList
) {
delete
fContNameList
; }
38
// if(fGeom ) delete fGeom;
39
40
}
41
42
void
FairBaseParSet::putParams
(
FairParamList
* l)
43
{
44
if
(!l) {
return
; }
45
l->
addObject
(
"Detector List"
,
fDetList
);
46
l->
addObject
(
"Event Generator"
,
fPriGen
);
47
l->
addObject
(
"FairGeoNodes List"
,
fGeoNodes
);
48
l->
add
(
"Beam Momentum Gev/c"
,
fBeamMom
);
49
l->
addObject
(
"Detector Geometry"
,
fGeom
);
50
l->
addObject
(
"Parameter containers list"
,
fContNameList
);
51
}
52
53
Bool_t
FairBaseParSet::getParams
(
FairParamList
* l)
54
{
55
if
(!l) {
return
kFALSE; }
56
if
(!l->
fillObject
(
"Detector List"
,
fDetList
)) {
return
kFALSE; }
57
if
(!l->
fillObject
(
"Event Generator"
,
fPriGen
)) {
return
kFALSE; }
58
if
(!l->
fillObject
(
"FairGeoNodes List"
,
fGeoNodes
)) {
return
kFALSE; }
59
if
(!l->
fill
(
"Beam Momentum Gev/c"
, &
fBeamMom
)) {
return
kFALSE; }
60
if
(!l->
fillObject
(
"Detector Geometry"
,
fGeom
)) {
return
kFALSE; }
61
if
(!l->
fillObject
(
"Parameter containers list"
,
fContNameList
)) {
return
kFALSE; }
62
return
kTRUE;
63
}
64
65
EicRoot
blob
master
base
FairBaseParSet.cxx
Built by
Jin Huang
. updated:
Mon Jan 22 2024 12:43:32
using
1.8.2 with
EIC GitHub integration