Anaphe Home Page Reference Documentation

Main Page     Namespaces     Classes     Source Code    

IHistoManager.h

Go to the documentation of this file.
00001 // 
00002 // Copyright (C) CERN, Geneva 
00003 // 
00004 // header file for class IHistoManager 
00005 // Created by: Andreas Pfeiffer  at Thu Sep  2 14:29:35 1999
00006 // 
00007 // Last update: 
00008 //              
00009 // 
00010 #ifndef INTERFACE_IHISTOMANAGER_H
00011 #define INTERFACE_IHISTOMANAGER_H 1
00012 
00013 #include <iostream>
00014 
00015 #include <vector>
00016 
00017 #ifndef ANAPHE_NO_NAMESPACE
00018 namespace Anaphe {
00019 #endif
00020 
00021   class IHistogram;
00022   class IHistogram1D;
00023   class IHistogram2D;
00024   class IHistogram3D;
00025   class IProfileHistogram;
00026 
00027   class IHistoFactory;
00028 
00029   class IHistoManager { 
00030 
00031   public: 
00032     virtual ~IHistoManager() { /* nop */; }
00033 
00034   public:
00035     virtual bool unregister(IHistogram * h) = 0;
00036 
00037   public:               // public methods
00038     virtual bool register1D(IHistogram1D * h) = 0;
00039     virtual bool register2D(IHistogram2D * h) = 0;
00040     virtual bool register3D(IHistogram3D * h) = 0;
00041     virtual bool registerProf(IProfileHistogram * h) = 0;
00042 
00043     virtual IHistogram1D * retrieveHisto1D(const char * label) = 0;
00044     virtual IHistogram2D * retrieveHisto2D(const char * label) = 0;
00045     virtual IHistogram3D * retrieveHisto3D(const char * label) = 0;
00046     virtual IProfileHistogram * retrieveProf(const char * label) = 0;
00047   
00048     virtual void deleteHisto(const char * label) = 0;
00049 
00050 #ifdef AIDA_DONT_USE_STD
00051     virtual void list(     ostream& os =      cout) = 0;
00052 #else
00053     virtual void list(std::ostream& os = std::cout) = 0;
00054 #endif
00055 
00056     virtual void disableOverwrite() = 0;
00057     virtual void enableOverwrite () = 0;
00058     virtual void disableWarnOverwrite() = 0;
00059     virtual void enableWarnOverwrite () = 0;
00060 
00061   public:               // public methods
00062     virtual void setFactory(IHistoFactory *f) = 0;
00063 
00064     // --------------------------------------------------------------------------------
00065 
00066     virtual IHistogram1D * create1D(const char * label, const char *title
00067                                     , int nBinsx, double xmin, double xmax
00068                                     , const char * options = 0) = 0;
00069     virtual IHistogram2D * create2D(const char * label, const char *title
00070                                     , int nBinsx, double xmin, double xmax
00071                                     , int nBinsy, double ymin, double ymax
00072                                     , const char * options = 0) = 0;
00073 
00074     virtual IHistogram3D * create3D(const char * label, const char *title
00075                                     , int nBinsx, double xmin, double xmax
00076                                     , int nBinsy, double ymin, double ymax
00077                                     , int nBinsz, double zmin, double zmax
00078                                     , const char * options = 0) = 0;
00079 
00081     virtual IProfileHistogram * createProfile(const char * label, const char *title
00082                                               , int nBinsx=10, double xmin=0, double xmax=10
00083                                               , const char *options = 0) = 0;
00084 
00086     virtual IHistogram1D * createDynamic1D(const char *label, const char *title, int nBinsx) = 0;
00087 
00089 #ifdef AIDA_DONT_USE_STD
00090     virtual IHistogram1D * create1DVar(const char *label, const char *title, 
00091                                        vector<float> binEdge,
00092                                        const char * options = 0 ) = 0;
00093 
00094     virtual IHistogram2D * create2DVar(const char *label, const char *title, 
00095                                        vector<float> binEdgeX,
00096                                        vector<float> binEdgeY,
00097                                        const char * options = 0 ) = 0;
00098 #else /* def AIDA_DONT_USE_STD */
00099     virtual IHistogram1D * create1DVar(const char *label, const char *title, 
00100                                        std::vector<float> binEdge,
00101                                        const char * options = 0 ) = 0;
00102 
00103     virtual IHistogram2D * create2DVar(const char *label, const char *title, 
00104                                        std::vector<float> binEdgeX,
00105                                        std::vector<float> binEdgeY,
00106                                        const char * options = 0 ) = 0;
00107 #endif /* def AIDA_DONT_USE_STD */
00108 
00109     // --------------------------------------------------------------------------------
00110 
00112     virtual IHistogram1D * load1D(const char * label) = 0;
00113     virtual IHistogram2D * load2D(const char * label) = 0;
00114     virtual IHistogram3D * load3D(const char * label) = 0;
00115     virtual IProfileHistogram * loadProf(const char * label) = 0;
00116 
00117     virtual void scratchHisto(const char * label) = 0;
00118 
00119     virtual void store(const char * label)  = 0;
00120 
00122     virtual void selectStore(const char *name, const char *topDir=0) = 0;
00123     virtual void mkdir(const char *name) = 0;
00124     virtual void rmdir(const char *name) = 0;
00125     virtual void cd   (const char *name) = 0;
00126     virtual void ls   ()          const  = 0;
00127     virtual void pwd  ()          const  = 0;
00128 
00129   }; 
00130 
00131 #ifndef ANAPHE_NO_NAMESPACE
00132 }; // end namespace Anaphe
00133 #endif
00134 
00135 extern "C" {
00136   Anaphe::IHistoManager * createIHistoManager();
00137 }
00138 #endif /* INTERFACE_IHISTOMANAGER_H */ 


Anaphe documentation generated by Doxygen (www.doxygen.org)