CMS 3D CMS Logo

/afs/cern.ch/work/a/aaltunda/public/www/CMSSW_5_3_13_patch3/src/SimCalorimetry/HcalSimAlgos/interface/HPDNoiseDataFrame.h

Go to the documentation of this file.
00001 #ifndef HPDLibrary_HPDNoiseDataFrame_h
00002 #define HPDLibrary_HPDNoiseDataFrame_h
00003 
00004 // --------------------------------------------------------
00005 // Object to store all timeslices of noise signal frame
00006 // Project: HPD noise library
00007 // Author: F.Ratnikov UMd, Jan. 15, 2008
00008 // $Id: HPDNoiseDataFrame.h,v 1.2 2008/08/04 22:07:08 fedor Exp $
00009 // --------------------------------------------------------
00010 
00011 #include "TObject.h"
00012 
00013 #include <iostream>
00014 #include <stdint.h>
00015 #include "DataFormats/HcalDetId/interface/HcalDetId.h"
00016 
00017 
00018 namespace {
00019   const unsigned int FRAMESIZE = 10;
00020 }
00021 
00022 class HPDNoiseDataFrame {
00023  public:
00024   HPDNoiseDataFrame () {};
00025   HPDNoiseDataFrame (HcalDetId fId, const float* fCharges);
00026   virtual ~HPDNoiseDataFrame ();
00028   HcalDetId id () const {return HcalDetId (mId);}
00030   float charge (unsigned i) const {return (i < FRAMESIZE) ? mCharge[i] : -1.;}
00032   const float* getFrame () const {return mCharge;}
00033  private:
00034   uint32_t mId;
00035   float mCharge [10];
00036 };
00037 
00039 std::ostream& operator<< (std::ostream&, const HPDNoiseDataFrame&);
00040     
00041 #endif