BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnNdetGeoPar.cxx
Go to the documentation of this file.
1/*************************************************************************************
2 *
3 * Class BmnNdetGeoPar
4 *
5 * Adopted for BMN by: Elena Litvinenko
6 * e-mail: litvin@nf.jinr.ru
7 * Version: 06-11-2015
8 * Modified by M.Golubeva July 2022
9 *
10 ************************************************************************************/
11
12#include "BmnNdetGeoPar.h"
13
14#include "BmnNdet.h"
15#include "FairParamList.h"
16
17#include <iomanip>
18#include <iostream>
19using namespace std;
20
21BmnNdetGeoPar::BmnNdetGeoPar(const char* name, const char* title, const char* context)
22 : FairParGenericSet(name, title, context)
23{
24
27}
28
30
31// probably the next funtions can be deleted
32
34{
35 if (fGeoSensNodes)
36 delete fGeoSensNodes;
37 if (fGeoPassNodes)
38 delete fGeoPassNodes;
39}
40
41void BmnNdetGeoPar::putParams(FairParamList* l)
42{
43 if (!l)
44 return;
45 l->addObject("FairGeoNodes Sensitive List", fGeoSensNodes);
46 l->addObject("FairGeoNodes Passive List", fGeoPassNodes);
47}
48
50{
51 if (!l)
52 return kFALSE;
53 if (!l->fillObject("FairGeoNodes Sensitive List", fGeoSensNodes))
54 return kFALSE;
55 if (!l->fillObject("FairGeoNodes Passive List", fGeoPassNodes))
56 return kFALSE;
57
58 return kTRUE;
59}
60
61//------ CheckIfSensitive -----------------------------------------------
62bool BmnNdetGeoPar::CheckIfSensitive(std::string name)
63{
64 return (name.find(SensitiveVolume_name_NICA) != std::string::npos)
65 || (name.find(SensitiveVolume_name_VETO) != std::string::npos);
66}
bool Bool_t
constexpr Bool_t kFALSE
constexpr Bool_t kTRUE
TObjArray * fGeoPassNodes
List of FairGeoNodes for sensitive volumes.
void clear(void)
Bool_t getParams(FairParamList *)
BmnNdetGeoPar(const char *name="BmnNdetGeoPar", const char *title="Ndet Geometry Parameters", const char *context="NdetDefaultContext")
List of FairGeoNodes for passive volumes.
static bool CheckIfSensitive(std::string name)
static const TString SensitiveVolume_name_VETO
void putParams(FairParamList *)
TObjArray * fGeoSensNodes
static const TString SensitiveVolume_name_NICA
Definition json.hpp:4446