/* * ScanPlot.hh * * Created on: Dec 24, 2014 * Author: Hovanes Egiyan */ #ifndef SCANPLOT_HH_ #define SCANPLOT_HH_ #include "math.h" #include #include #include //#include "ROOT.h" #include "TObject.h" #include "TGraph2DErrors.h" #include "TAxis.h" #include "ScanDetector.hh" class ScanCorrection; using namespace std; class ScanPlot : public TObject { protected: TGraph2DErrors* scanGraph; // Graph for the scan TGraph2DErrors* scanRawGraph; // Raw unnormalized graph string scanName; // Name of the scan string scanPlotName; // Name of the scan plot string scanDate; // Date when the scan was taken ScanDetector* scanDet; // Detector pointer for this plot ScanDetector* scanPosX; // Positioner pointer for this plot ScanDetector* scanPosY; // Positioner pointer for this plot ScanDetector* scanNormDet; // Normalization detector pointer for this plot bool scanNormalized; // Flag to indicate if this scan has been normalized public: ScanPlot(); // Default constructor ScanPlot( ScanDetector* det, ScanDetector* posX, ScanDetector* posY, string sName, string date, bool statErrFlag = true ); // Main constructor virtual ~ScanPlot(); virtual bool normalize(); virtual void applyCorrections( ScanCorrection& corr ); void virtual initialize( bool statErrFlag = true ); virtual string getName() const { return scanPlotName; } virtual string getScanName() const { return scanName; } virtual string getDate() const { return scanDate;} virtual string setDate( const string date ) { return (scanDate = date);} virtual ScanDetector* getDetector() const { return scanDet; } virtual ScanDetector* getPositionerX() const { return scanPosX; } virtual ScanDetector* getPositionerY() const { return scanPosY; } virtual TGraph2DErrors* getRawGraph() const { return scanRawGraph; } virtual TGraph2DErrors* getGraph() const { return scanGraph; } virtual ScanDetector* getNormDetector() const { return scanNormDet; } virtual ScanDetector* setNormDetector( const ScanDetector* normDet ) { return (scanNormDet = const_cast( normDet )); } virtual bool isNormalized() const { return scanNormalized; } virtual bool setNormailzied() { return (scanNormalized = true); } ClassDef(ScanPlot,0) }; #endif /* SCANPLOT_HH_ */