VMware GemFire Native Client Cache Reference  9.0.6
PersistenceManager.hpp
Go to the documentation of this file.
1 #ifndef __GEMFIRE_PERSISTENCEMANAGER_H__
2 #define __GEMFIRE_PERSISTENCEMANAGER_H__
3 /*=========================================================================
4  * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
5  * This product is protected by U.S. and international copyright
6  * and intellectual property laws. Pivotal products are covered by
7  * more patents listed at http://www.pivotal.io/patents.
8  *========================================================================
9  */
10 #include "gfcpp_globals.hpp"
11 #include "gf_types.hpp"
12 #include "DistributedSystem.hpp"
13 #include "ExceptionTypes.hpp"
14 #include "CacheableKey.hpp"
15 #include "Cacheable.hpp"
16 
21 #define MAX_PAGE_COUNT "MaxPageCount"
22 #define PAGE_SIZE "PageSize"
23 #define PERSISTENCE_DIR "PersistenceDirectory"
24 
25 namespace gemfire {
26 
27 
28 typedef PersistenceManagerPtr (*getPersistenceManagerInstance) (const RegionPtr&);
29 
40 public:
41 
42 
47  static PersistenceManagerPtr getPersistenceManager();
48 
59  virtual void write(const CacheableKeyPtr& key, const CacheablePtr& value, void *& PersistenceInfo)=0;
60 
61 
66  virtual bool writeAll()=0;
67 
73  virtual void init(const RegionPtr& region, PropertiesPtr& diskProperties)=0;
74 
75 
83  virtual CacheablePtr read(const CacheableKeyPtr& key, void *& PersistenceInfo)=0;
84 
85 
90  virtual bool readAll()=0;
91 
92 
100  virtual void destroy(const CacheableKeyPtr& key, void *& PersistenceInfo)=0;
101 
106  virtual void close()=0;
107 
108  PersistenceManager(const RegionPtr& regionPtr);
113  virtual ~PersistenceManager() = 0;
114 protected:
118 
119 };
120 
121 }; //namespace gemfire
122 #endif //ifndef __GEMFIRE_PERSISTENCEMANAGER_H__
PersistenceManager API for persistence and overflow.
Definition: PersistenceManager.hpp:36
This namespace contains all the GemFire C++ API classes, enumerations and globals.
Definition: Assert.hpp:19
#define CPPCACHE_EXPORT
Defines a GemFire CPPCACHE export.
Definition: gf_base.hpp:51
This abstract base class is the base class of all user objects that have the shared capability of ref...
Definition: SharedBase.hpp:31
const RegionPtr m_regionPtr
Region for this persistence manager.
Definition: PersistenceManager.hpp:117

GemFire C++ Cache API Documentation