//////////////////////////////////////////////////////////////////////// /// \class RAT::GeoPanelFactory /// /// \brief The Factory that constructs and positions panels in the detector /// /// \author Phil Jones /// \author Aksel Hallin -- contact person /// /// REVISION HISTORY:\n /// 07/09 : P.Jones - First Revision, new file. \n /// 07/12 : P.Jones - Refactor to use PANELINFO.\n /// /// \details Calls the relevant functions to build a panel, once built \n /// it will position the panel in the detector /// /// //////////////////////////////////////////////////////////////////////// #ifndef __RAT_GeoPanelFactory__ #define __RAT_GeoPanelFactory__ #include #include #include class G4VPhysicalVolume; class G4LogicalVolume; namespace RAT { class EnvelopeConstructor; class PanelBase; class GeoPanelFactory : public GeoFactory, public GeoPMTFactoryBase { public: /// Constructor, registers this as a factory GeoPanelFactory() : GeoFactory("panelbuilder") {}; /// The Function that constructs all the Panels in the volume this factory is set for /// /// @param[in] table defines the volume /// @param[in] checkOverlaps when placing virtual void Construct( DBLinkPtr table, const bool checkOverlaps ); protected: /// Construct the panels (logical volumes) /// /// @param[in] table defines the volume /// @param[in] checkOverlaps when placing void ConstructPanels( DBLinkPtr table, const bool checkOverlaps ); /// Place the panels in the detector /// /// @param[in] table defines the volume /// @param[in] checkOverlaps when placing void PlacePanels( DBLinkPtr table, const bool checkOverlaps ); /// Memory management void DeletePanels(); std::map fPanels; ///< Mapping between panel Id and the panel }; } // namespace RAT #endif