]> git.uio.no Git - u/mrichter/AliRoot.git/blob - AliGeant4/AliLVStructure.h
const additions
[u/mrichter/AliRoot.git] / AliGeant4 / AliLVStructure.h
1 // $Id$
2 // Category: geometry
3 //
4 // Author: I. Hrivnacova
5 //
6 // Class AliLVStructure
7 // --------------------
8 // Class that associates the name tree with logical volumes tree. 
9 // Used for printing volumes trees.  
10
11 #ifndef ALI_LV_STRUCTURE_H
12 #define ALI_LV_STRUCTURE_H
13
14 #include <globals.hh>
15 #include <g4rw/tpordvec.h>
16
17 class G4LogicalVolume;
18
19 class AliLVStructure 
20 {
21   public:
22     AliLVStructure(G4String aPath);
23     AliLVStructure(const AliLVStructure& right);
24     // --> protected 
25     // AliLVStructure();
26     virtual ~AliLVStructure();
27
28     // operators
29     AliLVStructure& operator=(const AliLVStructure& right);
30     G4int operator==(const AliLVStructure &right) const;
31
32     // methods
33     void AddNewVolume(G4LogicalVolume* lv, const G4String& treeStructure);
34     void ListTree() const;
35     void ListTreeLong() const;
36
37     // set methods
38     void SetVerboseLevel(G4int verbose); 
39 #ifdef ALICE_VISUALIZE
40     void SetTreeVisibility(G4bool visibility);       
41     void SetTreeColour(const G4String& colName);
42 #endif             
43
44     // get methods
45     G4LogicalVolume* GetVolume(const G4String& name) const;
46     G4LogicalVolume* FindVolume(const G4String& name) const;
47
48   protected:
49     AliLVStructure(); 
50
51   private:
52     // methods
53     AliLVStructure* FindSubDirectory(const G4String& subDir) const;
54     G4String ExtractDirName(const G4String& path) const;
55
56     // data members
57     G4RWTPtrOrderedVector<AliLVStructure>   fStructures;                     //.
58                                                 //vector of
59                                                 //contained structures
60     G4RWTPtrOrderedVector<G4LogicalVolume>  fLogicalVolumes;                 //.
61                                                 //vector of
62                                                 //contained logical volumes
63                                                 //(parallel to fStructures)
64     G4String  fPathName;     //full path name
65     G4String  fDirName;      //directory name
66     G4int     fVerboseLevel; //verbose level
67 };
68
69 #endif //ALI_LV_STRUCTURE_H
70