Red Hat Data Grid HotRod C++ Client  7.2.0
NearCacheConfiguration.h
Go to the documentation of this file.
1 /*
2  * NearCacheConfiguration.h
3  *
4  * Created on: Nov 29, 2016
5  * Author: rigazilla
6  */
7 
8 #ifndef INCLUDE_INFINISPAN_HOTROD_NEARCACHECONFIGURATION_H_
9 #define INCLUDE_INFINISPAN_HOTROD_NEARCACHECONFIGURATION_H_
10 
11 
13 
14 namespace infinispan {
15 namespace hotrod {
16 
24 };
25 
33 {
34 public:
35  NearCacheConfiguration(NearCacheMode mode=DISABLED, int maxEntries=0) : m_mode(mode), m_maxEntries(maxEntries) {}
36 
37  unsigned int getMaxEntries() const {
38  return m_maxEntries;
39  }
40 
41  void maxEntries(int maxEntries = 0) {
42  this->m_maxEntries = maxEntries;
43  }
44 
46  return m_mode;
47  }
48 
49  void mode(NearCacheMode mode = DISABLED) {
50  this->m_mode = mode;
51  }
52 private:
53  NearCacheMode m_mode=DISABLED;
54  unsigned int m_maxEntries=0;
55 };
56 }
57 }
58 
59 
60 #endif /* INCLUDE_INFINISPAN_HOTROD_NEARCACHECONFIGURATION_H_ */
unsigned int getMaxEntries() const
Definition: NearCacheConfiguration.h:37
NearCacheMode getMode() const
Definition: NearCacheConfiguration.h:45
#define HR_EXTERN
Definition: ImportExport.h:35
Definition: NearCacheConfiguration.h:32
void mode(NearCacheMode mode=DISABLED)
Definition: NearCacheConfiguration.h:49
void maxEntries(int maxEntries=0)
Definition: NearCacheConfiguration.h:41
Definition: NearCacheConfiguration.h:21
Definition: AuthenticationConfiguration.h:10
NearCacheMode
Definition: NearCacheConfiguration.h:20
Definition: NearCacheConfiguration.h:22
NearCacheConfiguration(NearCacheMode mode=DISABLED, int maxEntries=0)
Definition: NearCacheConfiguration.h:35