// class ElectronicsFactory // $Id: ElectronicsFactory.hh,v 1.13 2005/10/18 23:16:22 thea Exp $ // Factory method to build a version of the Euso Electronics Model // Singleton #ifndef __ELECTRONICS_FACTORY_H_ #define __ELECTRONICS_FACTORY_H_ #include "euso.hh" #include "EsafConfigurable.hh" #include "EsafMsgSource.hh" #include "EVector.hh" class EusoElectronics; class MacroCell; class Detector; class Photomultiplier; class FrontEndChip; class PmtGeometry; class Telemetry; class AnalogFrontEnd; class ElementaryCell; class MacroCellGeometry; // // FIXME: Electronics should be handled in a different way. Possibly by the detector it self // In principle troubles could appear in SimuApplication // class ElectronicsFactory : public EsafConfigurable, public EsafMsgSource { public: // singleton static ElectronicsFactory* Get(); // dtor virtual ~ElectronicsFactory(); EsafConfigClass(Electronics,ElectronicsFactory) // build the euso electronics according to the Config object virtual EusoElectronics* Build(); virtual EusoElectronics* GetEusoElectronics(); virtual Detector* MakeDetector(); // create a new detector according config file virtual Photomultiplier* MakePmt(Int_t, PmtGeometry*); // build the specified type of Pmt virtual FrontEndChip* MakeFrontEndChip( Int_t ); // build the specified type of FrontEndChip virtual AnalogFrontEnd* MakeAFEE( FrontEndChip*, Int_t ); // build the specified type of AFEE virtual MacroCell* MakeMacroCell(); // build the specified type of MacroCell virtual MacroCellGeometry* MakeMacroCellGeometry(MacroCell*); // build the specified type of MacroCellGeometry virtual ElementaryCell* MakeElementaryCell(); // build the specified type of elementary cell // virtual PmtGeometry* GetPmtGeometry( Int_t, Int_t ); virtual PmtGeometry* MakePmtGeometry( const EVector&, const EVector&, const EVector& ); // get pmt geometry virtual Telemetry* MakeTelemetry(); // get telemetry object private: // private constructor ElectronicsFactory(); // pointer to singleton static ElectronicsFactory* fMe; // Euso Electronics object EusoElectronics* fEusoElec; ClassDef(ElectronicsFactory,0) }; #endif