/export/rook2/users/build/gfcppsancout64/product/include/gfcpp/statistics/StatisticsFactory.hpp

Go to the documentation of this file.
00001 #ifndef  _GEMFIRE_STATISTICS_STATISTICSFACTORY_HPP_
00002 #define  _GEMFIRE_STATISTICS_STATISTICSFACTORY_HPP_
00003 /*=========================================================================
00004  * (c) Copyright 2004-2007, GemStone Systems, Inc. All Rights Reserved.
00005  * 1260 NW Waterhouse Ave., Suite 200,  Beaverton, OR 97006
00006  *=========================================================================
00007  */
00008 #include "../gfcpp_globals.hpp"
00009 #include "StatisticDescriptor.hpp"
00010 #include "StatisticsType.hpp"
00011 #include "../ExceptionTypes.hpp"
00012 #include "Statistics.hpp"
00013 
00017 namespace gemfire_statistics {
00018 
00039 class CPPCACHE_EXPORT StatisticsFactory  {
00040 protected:
00041   StatisticsFactory(){}
00042   StatisticsFactory(const StatisticsFactory &){}
00043 
00044 public:
00045 
00050   static StatisticsFactory* getExistingInstance();
00051 
00052   virtual  ~StatisticsFactory() {}
00053 
00060   virtual StatisticDescriptor* createIntCounter(const char* name, const char* description,const char* units, int8 largerBetter = true) =0;
00061 
00062 
00069   virtual StatisticDescriptor*  createLongCounter(const char* name, const char* description,const char* units, int8 largerBetter = true)=0;
00070 
00071 
00078   virtual StatisticDescriptor*  createDoubleCounter(const char* name, const char* description, const char* units, int8 largerBetter = true)=0;
00079 
00080 
00086   virtual StatisticDescriptor*  createIntGauge(const char* name, const char* description, const char* units,int8 largerBetter= false)=0;
00087 
00088 
00094   virtual StatisticDescriptor*  createLongGauge(const char* name, const char* description,const char* units,int8 largerBetter= false)=0;
00095 
00096 
00102   virtual StatisticDescriptor*  createDoubleGauge(const char* name, const char* description, const char* units, int8 largerBetter= false)=0;
00103 
00104 
00112   virtual StatisticsType* createType(const char* name, const char* description,
00113                                    StatisticDescriptor** stats, int32 statsLength)=0;
00114 
00115 
00121   virtual StatisticsType* findType(const char* name)=0;
00122 
00128   virtual Statistics* createStatistics(StatisticsType* type)=0;
00129 
00135    virtual Statistics* createStatistics(StatisticsType* type, const char* textId)=0;
00136 
00142    virtual Statistics* createStatistics(StatisticsType* type, const char* textId, int64 numericId)=0;
00143 
00149    virtual Statistics* createAtomicStatistics(StatisticsType* type)=0;
00150 
00156    virtual Statistics* createAtomicStatistics(StatisticsType* type, const char* textId)=0;
00157 
00158 
00164    virtual Statistics* createAtomicStatistics(StatisticsType* type, const char* textId, int64 numericId)=0;
00165 
00167    virtual Statistics* findFirstStatisticsByType( StatisticsType* type ) = 0;
00168 
00172    virtual const char* getName()=0;
00173 
00174 
00178    virtual int64 getId()=0;
00179    
00180 private:
00181   const StatisticsFactory& operator=( const StatisticsFactory& );
00182 
00183   };//class
00184 }; //namespace
00185 
00186 #endif //  _GEMFIRE__STATISTICS_STATISTICSFACTORY_HPP_ 

GemFire C++ Cache API Documentation