ATTPCROOT  0.3.0-alpha
A ROOT-based framework for analyzing data from active target detectors
AtTpcGeo.h
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 version 3 (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
8 #ifndef NEWDETECTORGEO_H
9 #define NEWDETECTORGEO_H
10 
11 #include <FairGeoSet.h>
12 
13 #include <Rtypes.h>
14 #include <TString.h>
15 
16 class TBuffer;
17 class TClass;
18 class TMemberInspector;
19 
20 class AtTpcGeo : public FairGeoSet {
21 
22 protected:
23  char modName[20]{}; // name of module
24  char eleName[20]{}; // substring for elements in module
25 public:
27  ~AtTpcGeo() {}
28  const char *getModuleName(Int_t);
29  const char *getEleName(Int_t);
30  inline Int_t getModNumInMod(const TString &);
31  ClassDef(AtTpcGeo, 1)
32 };
33 
34 inline Int_t AtTpcGeo::getModNumInMod(const TString &name)
35 {
41  return (Int_t)(name[11] - '0') - 1; //
42 }
43 
44 #endif
AtTpcGeo::getModNumInMod
Int_t getModNumInMod(const TString &)
Definition: AtTpcGeo.h:34
AtTpcGeo
Definition: AtTpcGeo.h:20
AtTpcGeo::AtTpcGeo
AtTpcGeo()
AtTpcGeo::eleName
char eleName[20]
Definition: AtTpcGeo.h:24
AtTpcGeo::getEleName
const char * getEleName(Int_t)
Definition: AtTpcGeo.cxx:41
AtTpcGeo::~AtTpcGeo
~AtTpcGeo()
Definition: AtTpcGeo.h:27
AtTpcGeo::getModuleName
const char * getModuleName(Int_t)
Definition: AtTpcGeo.cxx:30
AtTpcGeo::modName
char modName[20]
Definition: AtTpcGeo.h:23