FairRoot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FairTutorialDet4GeoPar.cxx
Go to the documentation of this file.
1 /********************************************************************************
2  * Copyright (C) 2014 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
3  * *
4  * This software is distributed under the terms of the *
5  * GNU Lesser General Public Licence (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
9 
10 #include "FairParamList.h" // for FairParamList
11 
12 #include <TObjArray.h> // for TObjArray
13 
15 
16 FairTutorialDet4GeoPar ::FairTutorialDet4GeoPar(const char* name, const char* title, const char* context)
17  : FairParGenericSet(name, title, context)
18  , fGeoSensNodes(new TObjArray())
19  , fGeoPassNodes(new TObjArray())
20  , fGlobalCoordinates(kFALSE)
21 {}
22 
24 {
25  delete fGeoSensNodes;
26  delete fGeoPassNodes;
27 }
28 
30 {
31  if (!l) {
32  return;
33  }
34  l->addObject("FairGeoNodes Sensitive List", fGeoSensNodes);
35  l->addObject("FairGeoNodes Passive List", fGeoPassNodes);
36  l->add("GlobalCoordinates", fGlobalCoordinates);
37 }
38 
40 {
41  if (!l) {
42  return kFALSE;
43  }
44  if (!l->fillObject("FairGeoNodes Sensitive List", fGeoSensNodes)) {
45  return kFALSE;
46  }
47  if (!l->fillObject("FairGeoNodes Passive List", fGeoPassNodes)) {
48  return kFALSE;
49  }
50  if (!l->fill("GlobalCoordinates", &fGlobalCoordinates)) {
51  return kFALSE;
52  }
53  return kTRUE;
54 }
FairTutorialDet4GeoPar(const char *name="FairTutorialDet4GeoPar", const char *title="FairTutorialDet4 Geometry Parameters", const char *context="TestDefaultContext")
void addObject(const Text_t *, TObject *)
void putParams(FairParamList *)
ClassImp(FairEventBuilder)
Bool_t fillObject(const Text_t *, TObject *)
Bool_t getParams(FairParamList *)
Bool_t fill(const Text_t *, Text_t *, const Int_t)
void add(FairParamObj &)