Logo ROOT  
Reference Guide
TGeoMedium.h
Go to the documentation of this file.
1 // @(#)root/geom:$Id$
2 // Author: Rene Brun 26/12/02
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TGeoMedium
13 #define ROOT_TGeoMedium
14 
15 #include "TGeoMaterial.h"
16 
17 ////////////////////////////////////////////////////////////////////////////
18 // //
19 // TGeoMedium - base class describing tracking media //
20 // //
21 ////////////////////////////////////////////////////////////////////////////
22 
23 class TGeoMedium : public TNamed
24 {
25 public:
26  enum EGeoMedium {
28  };
29 
30 protected:
31  Int_t fId; // unique Id
32  Double_t fParams[20]; // parameters
33  TGeoMaterial *fMaterial; // pointer to material
34 
35 // methods
36  TGeoMedium(const TGeoMedium&);
38 
39 public:
40  // constructors
41  TGeoMedium();
42  TGeoMedium(const char *name, Int_t numed, const TGeoMaterial *mat, Double_t *params=0);
43  TGeoMedium(const char *name, Int_t numed, Int_t imat, Int_t isvol, Int_t ifield,
44  Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin);
45  virtual ~TGeoMedium();
46  // methods
47  virtual Int_t GetByteCount() const {return sizeof(*this);}
48  Int_t GetId() const {return fId;}
49  Double_t GetParam(Int_t i) const {return fParams[i];}
50  void SetParam(Int_t i, Double_t val) {fParams[i] = val;}
51  char *GetPointerName() const;
52  TGeoMaterial *GetMaterial() const {return fMaterial;}
53  virtual void SavePrimitive(std::ostream &out, Option_t *option = "");
54  void SetId(Int_t id) {fId = id;}
55  void SetMaterial(TGeoMaterial *mat) {fMaterial = mat;}
56  virtual void SetCerenkovProperties(TObject* cerenkov) {fMaterial->SetCerenkovProperties(cerenkov);}
57  ClassDef(TGeoMedium, 1) // tracking medium
58 
59 };
60 
61 #endif
62 
TGeoMedium::kMedSavePrimitive
@ kMedSavePrimitive
Definition: TGeoMedium.h:27
TGeoMedium::SetCerenkovProperties
virtual void SetCerenkovProperties(TObject *cerenkov)
Definition: TGeoMedium.h:56
TGeoMedium::GetParam
Double_t GetParam(Int_t i) const
Definition: TGeoMedium.h:49
TGeoMedium::GetPointerName
char * GetPointerName() const
Provide a pointer name containing uid.
Definition: TGeoMedium.cxx:127
Option_t
const char Option_t
Definition: RtypesCore.h:66
TGeoMedium::fMaterial
TGeoMaterial * fMaterial
Definition: TGeoMedium.h:33
TGeoMedium::fId
Int_t fId
Definition: TGeoMedium.h:31
TGeoMedium::SavePrimitive
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save a primitive as a C++ statement(s) on output stream "out".
Definition: TGeoMedium.cxx:137
TGeoMedium::fParams
Double_t fParams[20]
Definition: TGeoMedium.h:32
TGeoMaterial::SetCerenkovProperties
virtual void SetCerenkovProperties(TObject *cerenkov)
Definition: TGeoMaterial.h:136
TGeoMedium::SetMaterial
void SetMaterial(TGeoMaterial *mat)
Definition: TGeoMedium.h:55
TGeoMaterial
Base class describing materials.
Definition: TGeoMaterial.h:36
id
XFontStruct * id
Definition: TGX11.cxx:109
TGeoMedium::GetId
Int_t GetId() const
Definition: TGeoMedium.h:48
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
TGeoMaterial.h
TGeoMedium::operator=
TGeoMedium & operator=(const TGeoMedium &)
assignment operator
Definition: TGeoMedium.cxx:106
BIT
#define BIT(n)
Definition: Rtypes.h:85
TGeoMedium::~TGeoMedium
virtual ~TGeoMedium()
Destructor.
Definition: TGeoMedium.cxx:120
TGeoMedium::GetByteCount
virtual Int_t GetByteCount() const
Definition: TGeoMedium.h:47
TGeoMedium::SetParam
void SetParam(Int_t i, Double_t val)
Definition: TGeoMedium.h:50
Double_t
double Double_t
Definition: RtypesCore.h:59
TGeoMedium::GetMaterial
TGeoMaterial * GetMaterial() const
Definition: TGeoMedium.h:52
TObject
Mother of all ROOT objects.
Definition: TObject.h:37
ClassDef
#define ClassDef(name, id)
Definition: Rtypes.h:325
TGeoMedium::EGeoMedium
EGeoMedium
Definition: TGeoMedium.h:26
name
char name[80]
Definition: TGX11.cxx:110
TGeoMedium::TGeoMedium
TGeoMedium()
Default constructor.
Definition: TGeoMedium.cxx:36
TGeoMedium
Media are used to store properties related to tracking and which are useful only when using geometry ...
Definition: TGeoMedium.h:24
TGeoMedium::SetId
void SetId(Int_t id)
Definition: TGeoMedium.h:54
int