5 #include "ReturnMatcher.hpp"
8 class MemcachedCluster {
10 using behavior_t = pair<memcached_behavior_t, uint64_t>;
11 using behaviors_t = vector<behavior_t>;
14 memcached_st memc{empty_memc};
15 ReturnMatcher returns{&memc};
18 explicit MemcachedCluster(Cluster &&cluster, behaviors_t to_set = {});
21 MemcachedCluster(const MemcachedCluster &) = delete;
22 MemcachedCluster &operator=(const MemcachedCluster &) = delete;
24 MemcachedCluster(MemcachedCluster &&mc);
25 MemcachedCluster &operator=(MemcachedCluster &&mc);
27 void enableBinaryProto(bool enable = true);
28 void enableBuffering(bool enable = true);
29 void enableReplication();
30 void enableUdp(bool enable = true);
33 static MemcachedCluster mixed();
34 static MemcachedCluster network();
35 static MemcachedCluster socket();
36 static MemcachedCluster udp();
38 #if LIBMEMCACHED_WITH_SASL_SUPPORT
39 static MemcachedCluster sasl();
46 static const memcached_st empty_memc;