Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:14:35

0001 #ifndef TkNoiseCalculator_H
0002 #define TkNoiseCalculator_H
0003 
0004 #include "CalibTracker/SiStripAPVAnalysis/interface/ApvAnalysis.h"
0005 #include "CalibTracker/SiStripAPVAnalysis/interface/TkStateMachine.h"
0006 
0007 /**
0008  * The abstract class for noise calculation/subtraction.
0009  */
0010 class TkNoiseCalculator {
0011 public:
0012   virtual ~TkNoiseCalculator() {}
0013   /** Return status flag indicating if noise values are usable */
0014   TkStateMachine* status() { return &theStatus; }
0015 
0016   virtual void setStripNoise(ApvAnalysis::PedestalType& in) = 0;
0017   /** Return reconstructed noise */
0018   virtual ApvAnalysis::PedestalType noise() const = 0;
0019   virtual float stripNoise(int) const = 0;
0020 
0021   /** Request that status flag be updated */
0022   virtual void updateStatus() = 0;
0023 
0024   virtual void resetNoise() = 0;
0025 
0026   //Actions
0027 
0028   /** Update noise with current event */
0029   virtual void updateNoise(ApvAnalysis::PedestalType&) = 0;
0030   /** Tell noise calculator that a new event is available */
0031   virtual void newEvent() {}
0032 
0033 protected:
0034   TkStateMachine theStatus;
0035 };
0036 
0037 #endif