VMware GemFire Native C++ Reference  9.1
AttributesMutator.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #ifndef GEODE_ATTRIBUTESMUTATOR_H_
4 #define GEODE_ATTRIBUTESMUTATOR_H_
5 
6 /*
7  * Licensed to the Apache Software Foundation (ASF) under one or more
8  * contributor license agreements. See the NOTICE file distributed with
9  * this work for additional information regarding copyright ownership.
10  * The ASF licenses this file to You under the Apache License, Version 2.0
11  * (the "License"); you may not use this file except in compliance with
12  * the License. You may obtain a copy of the License at
13  *
14  * http://www.apache.org/licenses/LICENSE-2.0
15  *
16  * Unless required by applicable law or agreed to in writing, software
17  * distributed under the License is distributed on an "AS IS" BASIS,
18  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19  * See the License for the specific language governing permissions and
20  * limitations under the License.
21  */
22 
23 #include "geode_globals.hpp"
24 #include "geode_types.hpp"
25 #include "ExpirationAction.hpp"
30 namespace apache {
31 namespace geode {
32 namespace client {
33 
34 class CacheListener;
35 class CacheLoader;
36 class CacheWriter;
37 
56  private:
57  RegionPtr m_region;
58 
59  public:
62  AttributesMutator(const RegionPtr& region);
63 
64  virtual ~AttributesMutator();
65 
73  int32_t setEntryIdleTimeout(int32_t idleTimeout);
74 
80  ExpirationAction::Action setEntryIdleTimeoutAction(
82 
90  int32_t setEntryTimeToLive(int32_t timeToLive);
91 
97  ExpirationAction::Action setEntryTimeToLiveAction(
99 
107  int32_t setRegionIdleTimeout(int32_t idleTimeout);
108 
113  ExpirationAction::Action setRegionIdleTimeoutAction(
114  ExpirationAction::Action action);
115 
123  int32_t setRegionTimeToLive(int32_t timeToLive);
124 
129  ExpirationAction::Action setRegionTimeToLiveAction(
130  ExpirationAction::Action action);
131 
138  uint32_t setLruEntriesLimit(uint32_t entriesLimit);
139 
145  void setCacheListener(const CacheListenerPtr& aListener);
146 
155  void setCacheListener(const char* libpath, const char* factoryFuncName);
156 
162  void setCacheLoader(const CacheLoaderPtr& aLoader);
163 
171  void setCacheLoader(const char* libpath, const char* factoryFuncName);
172 
178  void setCacheWriter(const CacheWriterPtr& aWriter);
179 
187  void setCacheWriter(const char* libpath, const char* factoryFuncName);
188 };
189 } // namespace client
190 } // namespace geode
191 } // namespace apache
192 
193 #endif // GEODE_ATTRIBUTESMUTATOR_H_
Each enum represents a predefined RegionAttributes in a Cache.
Definition: Assert.hpp:31
#define CPPCACHE_EXPORT
Defines a Geode CPPCACHE export.
Definition: geode_base.hpp:58
This abstract base class is the base class of all user objects that have the shared capability of ref...
Definition: SharedBase.hpp:40
Action
Definition: ExpirationAction.hpp:43
Supports modification of certain region attributes after the region has been created.
Definition: AttributesMutator.hpp:55
This namespace contains all the Geode C++ API classes, enumerations and globals.

Pivotal GemFire C++ Cache API Documentation