All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
H2D.h
Go to the documentation of this file.
1 #ifndef HISTOGRAMSVC_H2D_H
2 #define HISTOGRAMSVC_H2D_H 1
3 
5 #include "Generic2D.h"
6 #include "GaudiPI.h"
7 #include "TH2D.h"
8 
9 using namespace AIDA;
10 
11 namespace Gaudi {
12  class Histogram1D;
13 
20  class GAUDI_API Histogram2D : public DataObject, public Generic2D<IHistogram2D,TH2D> {
21  public:
23  Histogram2D();
25  Histogram2D(TH2D* rep);
27  virtual ~Histogram2D() {}
29  bool fill(double x,double y,double weight = 1.);
31  virtual bool setBinContents(int binIndexX,int binIndexY,int entries,
32  double height,double error,double centreX,
33  double centreY );
35  bool setRms( double rmsX,double rmsY );
36  // overwrite reset
37  bool reset();
39  void copyFromAida(const IHistogram2D& h);
41  virtual const CLID& clID() const { return classID(); }
42  static const CLID& classID() { return CLID_H2D; }
43  protected:
44  // cache sumwx and sumwy when setting contents since I don't have bin mean
45  double m_sumwx;
46  double m_sumwy;
47  };
48 }
49 #endif // HISTOGRAMSVC_H2D_H
static const CLID & classID()
Definition: H2D.h:42
virtual const CLID & clID() const
Retrieve reference to class defininition identifier.
Definition: H2D.h:41
GAUDI_API void fill(AIDA::IHistogram1D *histo, const double value, const double weight=1.0)
simple function to fill AIDA::IHistogram1D objects
Definition: Fill.cpp:37
virtual ~Histogram2D()
Destructor.
Definition: H2D.h:27
AIDA implementation for 2 D histograms using ROOT THD2.
Definition: H2D.h:20
unsigned int CLID
Class ID definition.
Definition: ClassID.h:9
This is a number of static methods for bootstrapping the Gaudi framework.
Definition: Bootstrap.h:15
double m_sumwy
Definition: H2D.h:46
double m_sumwx
Definition: H2D.h:45
#define GAUDI_API
Definition: Kernel.h:108
A DataObject is the base class of any identifiable object on any data store.
Definition: DataObject.h:31
Common AIDA implementation stuff for histograms and profiles using ROOT implementations.
Definition: Generic2D.h:30