]> git.uio.no Git - u/mrichter/AliRoot.git/blob - STRUCT/AliALIFE.h
Removing dependences on AliDAQ class (in raw)
[u/mrichter/AliRoot.git] / STRUCT / AliALIFE.h
1 #ifndef ALIALIFE_H
2 #define ALIALIFE_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 #include "TObject.h"
9 #include "TString.h"
10
11 class AliALIFE : public  TObject {
12  public:
13     AliALIFE(const char *name1, const char *name2);
14     AliALIFE();    
15     AliALIFE(const AliALIFE &rhs);
16
17     virtual ~AliALIFE() {}
18     void Cylinder(Float_t rmin, Float_t rmax,
19                   Float_t zmin, Float_t zmax,
20                   Float_t pos[3],
21                   const char* Material, 
22                   const char* Field="MF", 
23                   const char* Cuts="$UNSHIELDED");
24     void OnionCylinder(Float_t* r, Int_t nr, Float_t zmin, Float_t zmax,
25                        Float_t pos[3],
26                        const char** Materials,
27                        const char** Fields=0,
28                        const char** Cuts=0);
29     
30     void Cone(Float_t rmin1, Float_t rmin2,
31               Float_t rmax1, Float_t rmax2,
32               Float_t zmin, Float_t zmax,
33               Float_t pos[3],
34               const char* Material, 
35               const char* Field="MF", 
36               const char* Cuts="$UNSHIELDED");
37     
38     void OnionCone(Float_t* r1, Float_t* r2, Int_t nr,
39                    Float_t zmin, Float_t zmax,
40                    Float_t pos[3],
41                    const char** Materials,
42                    const char** Fields=0,
43                    const char** Cuts=0);
44
45     void PolyCone(Float_t* rmin, Float_t* rmax, Float_t* z, Int_t nz,
46                   Float_t pos[3], 
47                   const char* Material, 
48                   const char* Field="MF", 
49                   const char* Cuts="$UNSHIELDED");
50
51     void OnionPolyCone(Float_t** r , Float_t* z, Int_t nr, Int_t nz,
52                        Float_t pos[3], 
53                        const char** Materials,
54                        const char** Fields=0,
55                        const char** Cuts=0);
56     
57     void Comment(const char* Comment);
58
59     void Finish(Bool_t remove = 0);
60
61     void SetDefaultVolume(TString vol1, TString vol2) 
62         {fDefaultVolume1=vol1; fDefaultVolume2=vol2;}
63     
64     void SetDefaultVolume(TString vol) 
65         {fDefaultVolume1=vol;}
66
67  protected:
68     Int_t        fNBodies;          // current number of bodies
69     Int_t        fNVolumes;         // current number of volumes
70     TString       fBodyFile;        // File for Fluka bodies
71     TString       fVolumeFile;      // File for Fluka volumes
72     FILE         *fFile1;           // ! output file for fluka geometry in ALIFE format  
73     FILE         *fFile2;           // ! scratch file
74     TString      fDefaultVolume1;   // default external volume 1 
75     TString      fDefaultVolume2;   // default external volume 2   
76  private:
77     void BodyHeader();
78     void VolumeHeader();
79     void Copy(TObject &alife) const;
80
81     AliALIFE & operator = (const AliALIFE &rhs) {
82         rhs.Copy(*this);
83         return (*this);
84     }
85    ClassDef(AliALIFE,1)
86 };
87 #endif
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102