PandaRoot
PndFsmAbsDet.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 //--------------------------------------------------------------------------
14 // File and Version Information:
15 // $Id: FsmAbsDet.hh,v 1.5 2007/05/24 08:07:40 klausg Exp $
16 //
17 // Description:
18 // Class FsmAbsDet
19 //
20 // Abstract Class Interface for Fast Sim Detectors
21 //
22 // This software was developed for the PANDA collaboration. If you
23 // use all or part of it, please give an appropriate acknowledgement.
24 //
25 // Author List:
26 // Klaus Goetzen Original Author
27 //
28 // Copyright Information:
29 // Copyright (C) 2006 GSI
30 //
31 //------------------------------------------------------------------------
32 
33 #ifndef PNDFSMABSDET_H
34 #define PNDFSMABSDET_H
35 
36 //----------------------
37 // Base Class Headers --
38 //----------------------
39 
40 //-------------------------------
41 // Collaborating class Headers --
42 //-------------------------------
43 
44 //---------------
45 // C++ Headers --
46 //---------------
47 #include <string>
48 
49 #include "FsmDetTypes.h"
50 
51 #include "ArgList.h"
52 #include "TRandom3.h"
53 #include "TDatabasePDG.h"
54 
55 //--------------------------------------------
56 // Collaborating class forward declarations --
57 // -------------------------------------------
58 class PndFsmResponse;
59 class PndFsmTrack;
60 
61 class PndFsmAbsDet {
62  public:
63  //--------------------
64  // Public interface --
65  //--------------------
66 
67  //
68  // Constructors
69  //
70 
71  PndFsmAbsDet();
72  PndFsmAbsDet(ArgList &par);
73  // Destructor
74  //
75  virtual ~PndFsmAbsDet();
76 
77  //
78  // Accessors to contained information
79  //
80 
81  virtual PndFsmResponse *respond(PndFsmTrack *t) = 0;
82  virtual void print(std::ostream &o);
83 
84  const std::string &detName() { return _detName; }
85  void setName(std::string &name) { _detName = name; };
86  Bool_t doesPid() const { return _doesPid; };
87  void setStorePid(Bool_t doespid = kTRUE) { _doesPid = doespid; };
88 
89  protected:
90  virtual bool setParameter(std::string &name, double value);
91  virtual bool setParameter(std::string &name, std::string &value);
92 
93  virtual void initParameters();
94  void parseParameterList(ArgList &par);
95 
96  //
97  // Modifiers
98  //
99 
100  std::string _detName;
101  double _efficiency; // overall efficiency
102  TRandom3 *_rand;
103  TDatabasePDG *_fdbPDG;
104  Bool_t _doesPid;
105 };
106 
107 #endif
virtual PndFsmResponse * respond(PndFsmTrack *t)=0
double _efficiency
Definition: PndFsmAbsDet.h:101
virtual void print(std::ostream &o)
TDatabasePDG * _fdbPDG
Definition: PndFsmAbsDet.h:103
std::list< std::string > ArgList
Definition: ArgList.h:19
void setStorePid(Bool_t doespid=kTRUE)
Definition: PndFsmAbsDet.h:87
void parseParameterList(ArgList &par)
Bool_t _doesPid
Definition: PndFsmAbsDet.h:104
TRandom3 * _rand
Definition: PndFsmAbsDet.h:102
virtual void initParameters()
void setName(std::string &name)
Definition: PndFsmAbsDet.h:85
const std::string & detName()
Definition: PndFsmAbsDet.h:84
virtual bool setParameter(std::string &name, double value)
std::string _detName
Definition: PndFsmAbsDet.h:100
Bool_t doesPid() const
Definition: PndFsmAbsDet.h:86
virtual ~PndFsmAbsDet()