CMS 3D CMS Logo

CastorNumberingScheme.h

Go to the documentation of this file.
00001 #ifndef Forward_CastorNumberingScheme_h
00002 #define Forward_CastorNumberingScheme_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     Forward
00006 // Class  :     CastorNumberingScheme
00007 //
00016 //
00017 // Original Author: 
00018 //         Created:  Tue May 16 10:14:34 CEST 2006
00019 // $Id: CastorNumberingScheme.h,v 1.4 2008/03/04 11:31:10 katsas Exp $
00020 //
00021  
00022 // system include files
00023 
00024 // user include files
00025 
00026 
00027 #include "G4Step.hh"
00028 #include <boost/cstdint.hpp>
00029 
00030 class CastorNumberingScheme {
00031 
00032 public:
00033 
00034   CastorNumberingScheme();
00035   virtual ~CastorNumberingScheme();
00036 
00037   virtual uint32_t getUnitID(const G4Step* aStep) const;
00038 
00048   //  static uint32_t packIndex(int det, int z, int sector, int zmodule);
00049   //  static void   unpackIndex(const uint32_t& idx, int& det, int& z, int& sector, int& zmodule);
00050 
00051 
00052 static uint32_t packIndex(int z, int sector, int zmodule);
00053 static void   unpackIndex(const uint32_t& idx, int& z, int& sector, int& zmodule);
00054 
00055   // Utilities to get detector levels during a step
00056   int  detectorLevel(const G4Step*) const;
00057   void detectorLevel(const G4Step*, int&, int*, G4String*) const;
00058 
00059 private:
00060 
00061   int zsideScale;
00062   int sectorScale;
00063 
00064 };
00065 
00066 #endif

Generated on Tue Jun 9 17:46:54 2009 for CMSSW by  doxygen 1.5.4