2 * Copyright (C) 2006-2009 Brian Aker
5 * Use and distribution licensed under the BSD license. See
6 * the COPYING file in the parent directory for full text.
8 * Summary: Change the behavior of the memcached connection.
12 #ifndef __LIBMEMCACHED_BEHAVIOR_H__
13 #define __LIBMEMCACHED_BEHAVIOR_H__
20 memcached_return_t
memcached_behavior_set(memcached_st
*ptr
, const memcached_behavior_t flag
, uint64_t data
);
23 uint64_t memcached_behavior_get(memcached_st
*ptr
, const memcached_behavior_t flag
);
26 memcached_return_t
memcached_behavior_set_distribution(memcached_st
*ptr
, memcached_server_distribution_t type
);
29 memcached_server_distribution_t
memcached_behavior_get_distribution(memcached_st
*ptr
);
32 memcached_return_t
memcached_behavior_set_key_hash(memcached_st
*ptr
, memcached_hash_t type
);
35 memcached_hash_t
memcached_behavior_get_key_hash(memcached_st
*ptr
);
38 memcached_return_t
memcached_behavior_set_distribution_hash(memcached_st
*ptr
, memcached_hash_t type
);
41 memcached_hash_t
memcached_behavior_get_distribution_hash(memcached_st
*ptr
);
44 bool _is_auto_eject_host(const memcached_st
*ptr
);
47 const char *libmemcached_string_behavior(const memcached_behavior_t flag
);
50 const char *libmemcached_string_distribution(const memcached_server_distribution_t flag
);
56 #endif /* __LIBMEMCACHED_BEHAVIOR_H__ */