Shape

Macros

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
// Shape.h
//
/*! \class Shape
 * \brief Abstract Class of shape
 * 
 *
*/

#ifndef Shape_H
#define Shape_H

#include "TObject.h"

class Shape : public TObject {
public:
  //! return the value of the shape at a given time (given in clock unit)
  virtual double eval(double t) const = 0;
  //! return the value of the derivative of the shape at a given time (given in clock unit)
  virtual double derivative(double t) const = 0;
  //! return the value of the time of the max of the shape (in clock unit).
  virtual double getTimeOfMax() const = 0;
  //! Calling this method fill the shape corresponding to a given channel (tower, crystal and gain)
  virtual bool fillShapeFor(int tower = 0, int crystal = 0, int gain = 0) = 0;

  ClassDefOverride(Shape, 1)  // Definition of a general interface to pulse shapes
};

#endif