00001 #ifndef TMBCaloCell_H
00002 #define TMBCaloCell_H
00003
00004 #include "TObject.h"
00005
00017 class TMBCaloCell {
00018
00019 private:
00021 Float_t _E;
00022
00024 Char_t _ieta;
00025
00027 UChar_t _iphi;
00028
00030 UChar_t _ilyr;
00031
00033 UChar_t _flags;
00034
00035 public:
00037
00038 enum Flag {
00040 CAL_CELL = 0,
00042 NADA_CELL = 1,
00044 T42_CELL = 2 };
00045
00046 TMBCaloCell();
00047 TMBCaloCell(Char_t ieta, UChar_t iphi, UChar_t ilyr, Float_t E, UChar_t flags);
00048 virtual ~TMBCaloCell();
00049
00051 void Set(Char_t ieta, UChar_t iphi, UChar_t ilyr, Float_t E, UChar_t flags = 0);
00052
00054 Float_t E() const { return _E; }
00055
00057 Int_t ieta() const { return _ieta; }
00058
00060 Int_t iphi() const { return _iphi; }
00061
00063 Int_t layer() const { return _ilyr; }
00064
00066 Int_t flags() const { return _flags;}
00067
00069 Bool_t isNormalCell() const { return _flags == 0; }
00070
00072 Bool_t isNadaCell() const { return _flags & 0x0001; }
00073
00075 Bool_t isCalT42Cell() const { return _flags & 0x0002; }
00076
00077 ClassDef(TMBCaloCell, 1);
00078 };
00079
00080 #endif // TMBCaloCell