#ifndef HEPHIST2DARRAY_H #define HEPHIST2DARRAY_H // ---------------------------------------------------------------------- // // HepHist2DArray.h - class declaration for generic array of 2D histogram // // See HepHist1DArray.h for details. // // History: // 02-APR-99 Philippe Canal initial Draft #ifndef ZMENVIRONMENT_H #include "ZMutility/ZMenvironment.h" #endif #include #ifndef HEPOBJ_H #include "HepTuple/HepObj.h" #endif #ifndef ISOCXX__ISOCXX #include #endif ZM_BEGIN_NAMESPACE( zmht ) /* namespace zmht { */ class HepHist2D; class HepHist2DArray : public HepObj { friend class HepFileManager; public: typedef std::STL_VECTOR(HepHist2D*) dataArray; protected: HepHist2DArray( // constructor HepFileManager * mgr , const std::string & title , const dataArray & data ); // Used for dummy construction ... // the object is then not valid ... HepHist2DArray( ); // default constructor public: virtual ~HepHist2DArray(); // destructor virtual ZM_COVARIANT_TYPE(HepObj,HepHist2DArray) & makeClone( const std::string& title, const int id = 0) const; virtual ZM_COVARIANT_TYPE(HepObj,HepHist2DArray) & makeEmpty( const std::string& title, const int id = 0) const; virtual ZM_COVARIANT_TYPE(HepObj,HepHist2DArray) & makeClone( HepFileManager *manager, const std::string& title , const int id = 0) const; virtual ZM_COVARIANT_TYPE(HepObj,HepHist2DArray) & makeEmpty( HepFileManager *manager, const std::string& title , const int id = 0) const; virtual void reset(); virtual int length() const; virtual HepHist2D& operator[](int pos) const; virtual int nBinsX() const; // retrieve # of in-range X bins virtual int nBinsY() const; // retrieve # of in-range Y bins virtual float minX() const; // retrieve low end of binned X range virtual float minY() const; // retrieve high end of binned X range virtual float maxX() const; // retrieve low end of binned X range virtual float maxY() const; // retrieve high end of binned X range private: // forbidden operations, hence private HepHist2DArray( const HepHist2DArray & ); // copy constructor HepHist2DArray & operator=( const HepHist2DArray & ); // assignment dataArray data_; // array of Hist2D pointers int nBinsX_; // # of in-range bins float minX_; // lowest in-range value float maxX_; // highest in-range value int nBinsY_; // # of in-range bins float minY_; // lowest in-range value float maxY_; // highest in-range value }; ZM_END_NAMESPACE( zmht ) /* } // namespace zmht */ #endif // HEPHIST2DARRAY_H