/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/DetectorDescription/Identifier/Identifier-00-02-17/Identifier/EmcID.h

Go to the documentation of this file.
00001 #ifndef __EmcID_h__
00002 #define __EmcID_h__
00003 
00004 #include "Identifier/BesDetectorID.h"
00005 #include <string>
00006 #include <assert.h>
00007 
00008 class EmcID : public BesDetectorID
00009 {
00010  public:
00011    typedef Identifier::size_type  size_type; 
00012    typedef Identifier::value_type value_type; 
00013    
00015    EmcID();
00016    
00018    ~EmcID();
00019    
00021    static Identifier crystal_id (const unsigned int barrel_ec,
00022                                  const unsigned int theta_module,   
00023                                  const unsigned int phi_module 
00024                                  );
00025 
00026    static unsigned int getIntID (const unsigned int barrel_ec,
00027                                const unsigned int theta_module,
00028                                const unsigned int phi_module 
00029                               );
00030 
00031    static bool values_ok (const unsigned int barrel_ec,  
00032                           const unsigned int theta_module,
00033                           const unsigned int phi_module                    
00034                           );
00035    
00037    static bool is_barrel (const Identifier& id);  
00038    
00040    static unsigned int barrel_ec       (const Identifier& id) ;
00041    static unsigned int theta_module    (const Identifier& id) ; 
00042    static unsigned int phi_module      (const Identifier& id) ; 
00043    
00044    
00046    unsigned int theta_module_max  (const Identifier& id) ;
00047    unsigned int phi_module_max    (const Identifier& id) ;
00048 
00049    static unsigned int getTHETA_BARREL_MAX();
00050    static unsigned int getTHETA_BARREL_MIN();
00051    static unsigned int getTHETA_ENDCAP_MAX();
00052    static unsigned int getTHETA_ENDCAP_MIN();
00053    static unsigned int getPHI_BARREL_MAX();
00054    static unsigned int getPHI_BARREL_MIN();
00055    static unsigned int getPHI_ENDCAP_MAX(const unsigned int theta);
00056    static unsigned int getPHI_ENDCAP_MIN();
00057    static unsigned int getBARREL_EC_MAX();
00058    static unsigned int getBARREL_EC_MIN();
00059    static unsigned int getENDCAP_EAST();
00060    static unsigned int getBARREL();
00061    static unsigned int getENDCAP_WEST();
00062    
00063  private:
00064    static const unsigned int BARREL_EC_INDEX    = 16;
00065    static const unsigned int BARREL_EC_MASK     = 0x000F0000;
00066    
00067    static const unsigned int THETA_INDEX        = 8;
00068    static const unsigned int THETA_MASK         = 0x00003F00;
00069    
00070    static const unsigned int PHI_INDEX          = 0;
00071    static const unsigned int PHI_MASK           = 0x000000FF;
00072    
00073    static const unsigned int THETA_BARREL_MAX     = 43;
00074    static const unsigned int THETA_BARREL_MIN     = 0;
00075    static const unsigned int THETA_ENDCAP_MAX     = 5;
00076    static const unsigned int THETA_ENDCAP_MIN     = 0;
00077    
00078    static const unsigned int PHI_BARREL_MAX       = 119;
00079    static const unsigned int PHI_BARREL_MIN       = 0;
00080    static const unsigned int PHI_ENDCAP_MAX1      = 63;
00081    static const unsigned int PHI_ENDCAP_MAX2      = 79;
00082    static const unsigned int PHI_ENDCAP_MAX3      = 95;
00083    static const unsigned int PHI_ENDCAP_MIN       = 0;
00084    
00085    static const unsigned int BARREL_EC_MAX      = 2;
00086    static const unsigned int BARREL_EC_MIN      = 0;
00087    static const unsigned int ENDCAP_EAST        = 0;
00088    static const unsigned int BARREL             = 1;
00089    static const unsigned int ENDCAP_WEST        = 2;
00090 };
00091 
00092 #endif

Generated on Tue Nov 29 22:58:00 2016 for BOSS_7.0.2 by  doxygen 1.4.7