#ifndef HGEOUSER_H #define HGEOUSER_H #include "hgeoset.h" #include "hgeomedia.h" // // class for User defined volumes derived from baseclass HGeoDet (linked list); // The set 'user' contains up to 20 modules in the cave or in each sector. // class HGeoUser : public HGeoSet { public: HGeoUser(HGeoShapes & shapes) : HGeoSet() { // unique substring of the name of the module // 2nd and 3rd character is changed from 1...20 in readDet(...) detName="U01M"; // unique substring of the name of all daughtervolumes in a module eleName="U01"; // pointer to the class HGeoShapes pShapes=&shapes; numModules=20; noOfKeepIn= new int [20]; } ~HGeoUser(){delete [] noOfKeepIn;} // reads all user defined volumes from file using helperfunctions from the // baseclass int readDet(HGeoInfo & geoInfo); // reads all user defined volumes from database using helperfunctions from // the baseclass int readDet(HGeoInfo & geoInfo, HGeoMedia & geomedia); // creates all modules in the cave or in all sectors if they are defined // and if the inout-flag for the mothervolume is 1 int createDet(HGeoInfo & geoInfo, HGeoMedia & geomedia); // helperfuntion to changed the 2nd and 3rd character in the names // detName and eleName from 1...20 void changeName(HString & name, int firstPos, int no); protected: // maximum number of modules int numModules; // array to store for each module the number of sectors where the module // is defined // ( noOfKeepIn[i-1]=0 if not defined, else >=1 ) int *noOfKeepIn; }; #endif