//////////////////////////////////////////////////////////////////// /// \class RAT::PosGen_ELLIE /// /// \brief Selects a given fibre position for vertex position. /// /// \author Jeanne R Wilson -- contact person /// /// REVISION HISTORY:\n /// 29/10/13 : J.Wilson - First version (breakout from Gen_ELLIE top /// level generator /// 07-02-2017: N. Barros - Added concrete instance of BeginOfRun /// /// \details Choose the fibre via its id as a string (ratdb table index) /// /generator/pos/set fibreid /// //////////////////////////////////////////////////////////////////// #ifndef __RAT_PosGen_ELLIE__ #define __RAT_PosGen_ELLIE__ #include #include #include namespace RAT { class PosGen_ELLIE : public GLG4PosGen { public: /// Constructor sets the default db name PosGen_ELLIE( const std::string& dbname = std::string( "posellie" )); /// Destructor virtual ~PosGen_ELLIE() { }; /// Initialise parameters from DB void Init(); /// interface for generating the position virtual void GeneratePosition( G4ThreeVector& argResult ); /// interface for setting the state virtual void SetState( G4String newValues ); /// interface for getting the state virtual G4String GetState() const; virtual void BeginOfRun(); protected: G4ThreeVector fPosition; /// fibre position G4bool fInitDB; /// flag for DB initialisation std::string fFibreID; /// fibre id (state) }; } // namespace RAT #endif