build-artifacts/win/product/include/gfcpp/statistics/Statistics.hpp

Go to the documentation of this file.
00001 #ifndef _GEMFIRE_STATISTICS_STATISTICS_HPP_
00002 #define _GEMFIRE_STATISTICS_STATISTICS_HPP_
00003 /*=========================================================================
00004  * Copyright (c) 2004-2014 Pivotal Software, Inc. All Rights Reserved.
00005  * This product is protected by U.S. and international copyright
00006  * and intellectual property laws. Pivotal products are covered by
00007  * more patents listed at http://www.pivotal.io/patents.
00008  *=========================================================================
00009  */
00010 
00011 #include "../gfcpp_globals.hpp" 
00012 #include "StatisticsType.hpp"
00013 #include "StatisticDescriptor.hpp"                                                                               
00014                                                                                 
00018 namespace gemfire_statistics {
00023 class CPPCACHE_EXPORT Statistics {
00024 
00025  public  :
00032    virtual void close()=0;
00033 
00035 
00047    virtual int32 nameToId(const char* name)=0;
00048 
00049   
00061    virtual StatisticDescriptor* nameToDescriptor(const char* name)=0;
00062 
00066    virtual int64 getUniqueId()=0;
00067 
00071    virtual  StatisticsType* getType()=0;
00075    virtual  const char* getTextId()=0;
00080 virtual int64 getNumericId()=0;  
00090    virtual  bool isAtomic()=0;
00097    virtual  bool isShared()=0;
00101    virtual  bool isClosed()=0;
00102   
00104 
00115    virtual void setInt(int32 id, int32 value)=0;
00116 
00127    virtual void setInt(char* name, int32 value)=0;
00128 
00140    virtual void setInt(StatisticDescriptor* descriptor, int32 value)=0;
00141 
00155  virtual void setLong(int32 id, int64 value) = 0; 
00167    virtual void setLong(StatisticDescriptor* descriptor, int64 value)=0;
00168 
00179    virtual void setLong(char* name, int64 value)=0;
00180 
00191    virtual void setDouble(int32 id, double value)=0;
00192 
00204    virtual void setDouble(StatisticDescriptor* descriptor, double value)=0;
00215    virtual void setDouble(char* name, double value)=0;
00216 
00218 
00227    virtual int32 getInt(int32 id)=0;
00228 
00239    virtual int32 getInt(StatisticDescriptor* descriptor)=0;
00250    virtual int32 getInt(char* name)=0;
00251 
00260    virtual int64 getLong(int32 id)=0;
00261 
00262 
00273    virtual int64 getLong(StatisticDescriptor* descriptor)=0;
00284    virtual int64 getLong(char* name)=0;
00285 
00294    virtual double getDouble(int32 id)=0;
00295 
00306    virtual double getDouble(StatisticDescriptor* descriptor)=0;
00317    virtual double getDouble(char* name)=0;
00318 
00327 //   virtual Number get(StatisticDescriptor* descriptor)=0;
00328 
00335 //   virtual Number get(char* name)=0;
00336 
00345     virtual int64 getRawBits(StatisticDescriptor* descriptor)=0;
00346 
00353    // virtual double getRawBits(char* name)=0;
00354 
00356 
00370    virtual int32 incInt(int32 id, int32 delta)=0;
00371 
00385    virtual int32 incInt(StatisticDescriptor* descriptor, int32 delta)=0;
00386 
00399    virtual int32 incInt(char* name, int32 delta)=0;
00400 
00414    virtual int64 incLong(int32 id, int64 delta)=0;
00415 
00430    virtual int64 incLong(StatisticDescriptor* descriptor, int64 delta)=0;
00444    virtual int64 incLong(char* name, int64 delta)=0;
00445 
00459    virtual double incDouble(int32 id, double delta)=0;
00460 
00475    virtual double incDouble(StatisticDescriptor* descriptor, double delta)=0;
00489    virtual double incDouble(char* name, double delta)=0;
00490 
00491 protected:   
00495    virtual ~Statistics()=0; 
00496 };//class
00497 
00498 };//namespace
00499 
00500 #endif // _GEMFIRE_STATISTICS_STATISTICS_HPP_

GemFire C++ Cache API Documentation