memcached 0.10 → 0.11

Sign up to get free protection for your applications and to get access to all the features.
data.tar.gz.sig CHANGED
Binary file
data/CHANGELOG CHANGED
@@ -1,7 +1,9 @@
1
1
 
2
- v0.10. Move to libmemcached 0.20. Failover support. Close consistent hashing bugs.
2
+ v0.11. Update to libmemcached 0.22. Support hostname lookups. Register %freefunc for MemcachedSt and remove destroy() method. Use new built-in behavior for namespacing. Raise on version mismatch. Remove private hash function. Fix bug related to socket size behavior reset when struct is initialized with missing servers (Jeffrey Hardy). WARNING! If you use a namespace, this version will effectively invalidate your entire cache.
3
3
 
4
- v0.9. Move to libmemcached 0.19. Add some failover tests, but we are still waiting on libmemcached's replication branch for them to actually be useful. Fix CAS bug (ktheory).
4
+ v0.10. Update to libmemcached 0.20. Failover support. Close consistent hashing bugs.
5
+
6
+ v0.9. Update to libmemcached 0.19. Add some failover tests, but we are still waiting on libmemcached's replication branch for them to actually be useful. Fix CAS bug (ktheory).
5
7
 
6
8
  v0.8.1. Disable NotFound backtraces for speed (Blaine Cook).
7
9
 
@@ -4,6 +4,7 @@
4
4
  This chart shows which versions of the Ruby library are compatible with which versions of libmemcached.
5
5
 
6
6
  <b>Library version</b>:: <b>libmemcached version</b>
7
+ 0.11:: 0.22
7
8
  0.10:: 0.20
8
9
  0.9:: 0.19
9
10
  0.8:: 0.16
data/Manifest CHANGED
@@ -12,9 +12,9 @@ lib/memcached/rails.rb
12
12
  lib/memcached.rb
13
13
  LICENSE
14
14
  Manifest
15
+ Rakefile
15
16
  README
16
17
  test/profile/benchmark.rb
17
- test/profile/key.rb
18
18
  test/profile/profile.rb
19
19
  test/profile/valgrind.rb
20
20
  test/setup.rb
data/README CHANGED
@@ -22,14 +22,14 @@ The <b>memcached</b> library wraps the pure-C libmemcached client via SWIG.
22
22
 
23
23
  == Installation
24
24
 
25
- You need Ruby 1.8.6, and {libmemcached 0.20}[http://tangent.org/552/libmemcached.html]. Other versions are not supported. You also need {memcached itself}[http://www.danga.com/memcached/] if you want to test against a local server.
25
+ You need Ruby 1.8.6, and {libmemcached 0.21}[http://tangent.org/552/libmemcached.html]. Other versions are not supported. You also need {memcached itself}[http://www.danga.com/memcached/] if you want to test against a local server.
26
26
 
27
- For Linux, download and extract the {libmemcached tarball}[http://download.tangent.org/libmemcached-0.20.tar.gz]. Then run:
27
+ For Linux, download and extract the {libmemcached tarball}[http://download.tangent.org/libmemcached-0.21.tar.gz]. Then run:
28
28
  ./configure
29
29
  make && sudo make install
30
30
 
31
31
  For OS X, you may be able to install it from MacPorts:
32
- sudo port install libmemcached @0.20
32
+ sudo port install libmemcached @0.21
33
33
 
34
34
  Now install the gem:
35
35
  sudo gem install memcached --no-rdoc --no-ri
@@ -45,7 +45,7 @@ Start a local memcached server:
45
45
  Now, in Ruby, require the library and instantiate a Memcached object at a global level:
46
46
 
47
47
  require 'memcached'
48
- $cache = Memcached.new("127.0.0.1:11211")
48
+ $cache = Memcached.new("localhost:11211")
49
49
 
50
50
  Now you can set things and get things:
51
51
 
@@ -0,0 +1,30 @@
1
+ require 'echoe'
2
+
3
+ Echoe.new("memcached") do |p|
4
+ p.author = "Evan Weaver"
5
+ p.project = "fauna"
6
+ p.summary = "An interface to the libmemcached C client."
7
+ p.url = "http://blog.evanweaver.com/files/doc/fauna/memcached/"
8
+ p.docs_host = "blog.evanweaver.com:~/www/bax/public/files/doc/"
9
+ p.rdoc_pattern = /README|TODO|LICENSE|CHANGELOG|BENCH|COMPAT|exceptions|behaviors|rails.rb|memcached.rb/
10
+ end
11
+
12
+ task :exceptions do
13
+ $LOAD_PATH << "lib"
14
+ require 'memcached'
15
+ Memcached.constants.sort.each do |const_name|
16
+ const = Memcached.send(:const_get, const_name)
17
+ next if const == Memcached::Success or const == Memcached::Stored
18
+ if const.is_a? Class and const < Memcached::Error
19
+ puts "* Memcached::#{const_name}"
20
+ end
21
+ end
22
+ end
23
+
24
+ task :valgrind do
25
+ exec("valgrind --tool=memcheck --leak-check=yes --show-reachable=no --num-callers=15 --track-fds=yes ruby #{File.dirname(__FILE__)}/test/profile/valgrind.rb")
26
+ end
27
+
28
+ task :profile do
29
+ exec("ruby #{File.dirname(__FILE__)}/test/profile/profile.rb")
30
+ end
data/TODO CHANGED
@@ -1,4 +1,4 @@
1
1
 
2
- * Test consistent hashing
3
- * Verify libmemcached version
4
- * Support hostname looks with caching behavior
2
+ * Verify that DNS lookups are getting cached
3
+ * Check for memory leaks in Valgrind after free callback change
4
+ * Re-run benchmarks
@@ -11,6 +11,9 @@
11
11
 
12
12
  %include "typemaps.i"
13
13
 
14
+ // Register libmemcached's struct free function to prevent memory leaks
15
+ %freefunc memcached_st "memcached_free";
16
+
14
17
  //// Input maps
15
18
 
16
19
  %apply unsigned short { uint8_t };
@@ -26,7 +29,7 @@
26
29
  $2 = (size_t *) malloc(($3+1)*sizeof(size_t));
27
30
  $1 = (char **) malloc(($3+1)*sizeof(char *));
28
31
  for(i = 0; i < $3; i ++) {
29
- $2[i] = strlen(StringValuePtr(RARRAY_PTR($input)[i]));
32
+ $2[i] = RSTRING(RARRAY_PTR($input)[i])->len;
30
33
  $1[i] = StringValuePtr(RARRAY_PTR($input)[i]);
31
34
  }
32
35
  }
@@ -36,20 +39,25 @@
36
39
  }
37
40
 
38
41
  // Generic strings
39
- %typemap(in) (char *str, size_t len) {
42
+ %typemap(in) (const char *str, size_t len) {
40
43
  $1 = STR2CSTR($input);
41
44
  $2 = (size_t) RSTRING($input)->len;
42
45
  };
43
46
 
44
- %apply (char *str, size_t len) {
45
- (char *namespace, size_t namespace_length),
46
- (char *key, size_t key_length),
47
- (char *value, size_t value_length)
47
+ // Void type strings without lengths for prefix_key callback
48
+ %typemap(in) (void *data) {
49
+ $1 = STR2CSTR($input);
50
+ };
51
+
52
+ %apply (const char *str, size_t len) {
53
+ (const char *namespace, size_t namespace_length),
54
+ (const char *key, size_t key_length),
55
+ (const char *value, size_t value_length)
48
56
  };
49
57
 
50
58
  // Key strings with same master key
51
- // XXX This will have to go once people start doing client-side replication and actually need to set the master key
52
- %typemap(in) (char *master_key, size_t master_key_length, char *key, size_t key_length) {
59
+ // This will have to go if people actually want to set the master key separately
60
+ %typemap(in) (const char *master_key, size_t master_key_length, const char *key, size_t key_length) {
53
61
  $3 = $1 = STR2CSTR($input);
54
62
  $4 = $2 = (size_t) RSTRING($input)->len;
55
63
  };
@@ -67,7 +75,7 @@
67
75
  $result = INT2FIX($1);
68
76
  };
69
77
 
70
- // String
78
+ // String for memcached_fetch
71
79
  %typemap(in, numinputs=0) (char *key, size_t *key_length) {
72
80
  char string[256];
73
81
  size_t length = 0;
@@ -97,42 +105,20 @@
97
105
 
98
106
  %include "/opt/local/include/libmemcached/memcached.h"
99
107
  %include "/opt/local/include/libmemcached/memcached_constants.h"
108
+ %include "/opt/local/include/libmemcached/memcached_get.h"
100
109
  %include "/opt/local/include/libmemcached/memcached_storage.h"
101
110
  %include "/opt/local/include/libmemcached/memcached_result.h"
102
111
  %include "/opt/local/include/libmemcached/memcached_server.h"
103
112
 
104
113
  //// Custom C functions
105
114
 
106
- // Namespace and validate key. We could avoid several more dispatches and allocations if we called this from the libmemcached wrappers directly.
107
- VALUE ns(char *namespace, size_t namespace_length, char *key, size_t key_length);
108
- %{
109
- VALUE ns(char *namespace, size_t namespace_length, char *key, size_t key_length) {
110
- char namespaced_key[250];
111
- size_t namespaced_key_length = namespace_length + key_length;
112
-
113
- if (namespaced_key_length > 250)
114
- namespaced_key_length = 250;
115
-
116
- strncpy(namespaced_key, namespace, namespace_length);
117
- strncpy(namespaced_key + namespace_length, key, namespaced_key_length - namespace_length);
118
-
119
- int i;
120
- for (i = 0; i < namespaced_key_length; i++)
121
- if ((namespaced_key[i] < 33) || (namespaced_key[i] > 126))
122
- // Outside printable range
123
- namespaced_key[i] = '_';
124
-
125
- return rb_str_new(namespaced_key, namespaced_key_length);
126
- };
127
- %}
128
-
129
115
  //// Manual wrappers
130
116
 
131
117
  // Single get. SWIG likes to use SWIG_FromCharPtr instead of SWIG_FromCharPtrAndSize because
132
118
  // of the retval/argout split, so it truncates return values with \0 in them.
133
- VALUE memcached_get_rvalue(memcached_st *ptr, char *key, size_t key_length, uint32_t *flags, memcached_return *error);
119
+ VALUE memcached_get_rvalue(memcached_st *ptr, const char *key, size_t key_length, uint32_t *flags, memcached_return *error);
134
120
  %{
135
- VALUE memcached_get_rvalue(memcached_st *ptr, char *key, size_t key_length, uint32_t *flags, memcached_return *error) {
121
+ VALUE memcached_get_rvalue(memcached_st *ptr, const char *key, size_t key_length, uint32_t *flags, memcached_return *error) {
136
122
  VALUE ret;
137
123
  size_t value_length;
138
124
  char *value = memcached_get(ptr, key, key_length, &value_length, flags, error);
@@ -190,6 +176,3 @@ memcached_stat_st *memcached_select_stat_at(memcached_st *in_ptr, memcached_stat
190
176
  return &(stat_ptr[index]);
191
177
  };
192
178
  %}
193
-
194
- // Expose the hash generation function, which is not included in any header
195
- unsigned int memcached_generate_hash(memcached_st *ptr, char *key, size_t key_length);
@@ -1,6 +1,6 @@
1
1
  /* ----------------------------------------------------------------------------
2
2
  * This file was automatically generated by SWIG (http://www.swig.org).
3
- * Version 1.3.33
3
+ * Version 1.3.36
4
4
  *
5
5
  * This file is not intended to be easily readable and contains a number of
6
6
  * coding conventions designed to improve portability and efficiency. Do not make
@@ -51,6 +51,12 @@
51
51
  # endif
52
52
  #endif
53
53
 
54
+ #ifndef SWIG_MSC_UNSUPPRESS_4505
55
+ # if defined(_MSC_VER)
56
+ # pragma warning(disable : 4505) /* unreferenced local function has been removed */
57
+ # endif
58
+ #endif
59
+
54
60
  #ifndef SWIGUNUSEDPARM
55
61
  # ifdef __cplusplus
56
62
  # define SWIGUNUSEDPARM(p)
@@ -154,6 +160,12 @@
154
160
  # endif
155
161
  #endif
156
162
 
163
+ #ifndef SWIG_MSC_UNSUPPRESS_4505
164
+ # if defined(_MSC_VER)
165
+ # pragma warning(disable : 4505) /* unreferenced local function has been removed */
166
+ # endif
167
+ #endif
168
+
157
169
  #ifndef SWIGUNUSEDPARM
158
170
  # ifdef __cplusplus
159
171
  # define SWIGUNUSEDPARM(p)
@@ -224,7 +236,7 @@
224
236
 
225
237
  /* This should only be incremented when either the layout of swig_type_info changes,
226
238
  or for whatever reason, the runtime changes incompatibly */
227
- #define SWIG_RUNTIME_VERSION "3"
239
+ #define SWIG_RUNTIME_VERSION "4"
228
240
 
229
241
  /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
230
242
  #ifdef SWIG_TYPE_TABLE
@@ -259,6 +271,7 @@
259
271
 
260
272
  /* Flags for pointer conversions */
261
273
  #define SWIG_POINTER_DISOWN 0x1
274
+ #define SWIG_CAST_NEW_MEMORY 0x2
262
275
 
263
276
  /* Flags for new pointer objects */
264
277
  #define SWIG_POINTER_OWN 0x1
@@ -399,10 +412,10 @@ SWIGINTERNINLINE int SWIG_CheckState(int r) {
399
412
  extern "C" {
400
413
  #endif
401
414
 
402
- typedef void *(*swig_converter_func)(void *);
415
+ typedef void *(*swig_converter_func)(void *, int *);
403
416
  typedef struct swig_type_info *(*swig_dycast_func)(void **);
404
417
 
405
- /* Structure to store inforomation on one type */
418
+ /* Structure to store information on one type */
406
419
  typedef struct swig_type_info {
407
420
  const char *name; /* mangled name of this type */
408
421
  const char *str; /* human readable name of this type */
@@ -529,8 +542,8 @@ SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *into) {
529
542
  Cast a pointer up an inheritance hierarchy
530
543
  */
531
544
  SWIGRUNTIMEINLINE void *
532
- SWIG_TypeCast(swig_cast_info *ty, void *ptr) {
533
- return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr);
545
+ SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
546
+ return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
534
547
  }
535
548
 
536
549
  /*
@@ -840,12 +853,44 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
840
853
  #ifndef RSTRING_PTR
841
854
  # define RSTRING_PTR(x) RSTRING(x)->ptr
842
855
  #endif
856
+ #ifndef RSTRING_END
857
+ # define RSTRING_END(x) (RSTRING_PTR(x) + RSTRING_LEN(x))
858
+ #endif
843
859
  #ifndef RARRAY_LEN
844
860
  # define RARRAY_LEN(x) RARRAY(x)->len
845
861
  #endif
846
862
  #ifndef RARRAY_PTR
847
863
  # define RARRAY_PTR(x) RARRAY(x)->ptr
848
864
  #endif
865
+ #ifndef RFLOAT_VALUE
866
+ # define RFLOAT_VALUE(x) RFLOAT(x)->value
867
+ #endif
868
+ #ifndef DOUBLE2NUM
869
+ # define DOUBLE2NUM(x) rb_float_new(x)
870
+ #endif
871
+ #ifndef RHASH_TBL
872
+ # define RHASH_TBL(x) (RHASH(x)->tbl)
873
+ #endif
874
+ #ifndef RHASH_ITER_LEV
875
+ # define RHASH_ITER_LEV(x) (RHASH(x)->iter_lev)
876
+ #endif
877
+ #ifndef RHASH_IFNONE
878
+ # define RHASH_IFNONE(x) (RHASH(x)->ifnone)
879
+ #endif
880
+ #ifndef RHASH_SIZE
881
+ # define RHASH_SIZE(x) (RHASH(x)->tbl->num_entries)
882
+ #endif
883
+ #ifndef RHASH_EMPTY_P
884
+ # define RHASH_EMPTY_P(x) (RHASH_SIZE(x) == 0)
885
+ #endif
886
+ #ifndef RSTRUCT_LEN
887
+ # define RSTRUCT_LEN(x) RSTRUCT(x)->len
888
+ #endif
889
+ #ifndef RSTRUCT_PTR
890
+ # define RSTRUCT_PTR(x) RSTRUCT(x)->ptr
891
+ #endif
892
+
893
+
849
894
 
850
895
  /*
851
896
  * Need to be very careful about how these macros are defined, especially
@@ -1321,6 +1366,7 @@ SWIG_Ruby_AppendOutput(VALUE target, VALUE o) {
1321
1366
  #define SWIG_MangleStr(value) SWIG_Ruby_MangleStr(value)
1322
1367
  #define SWIG_CheckConvert(value, ty) SWIG_Ruby_CheckConvert(value, ty)
1323
1368
 
1369
+ #include "assert.h"
1324
1370
 
1325
1371
  /* -----------------------------------------------------------------------------
1326
1372
  * pointers/data manipulation
@@ -1582,8 +1628,11 @@ SWIG_Ruby_ConvertPtrAndOwn(VALUE obj, void **ptr, swig_type_info *ty, int flags,
1582
1628
  tc = SWIG_TypeCheck(c, ty);
1583
1629
  if (!tc) {
1584
1630
  return SWIG_ERROR;
1631
+ } else {
1632
+ int newmemory = 0;
1633
+ *ptr = SWIG_TypeCast(tc, vptr, &newmemory);
1634
+ assert(!newmemory); /* newmemory handling not yet implemented */
1585
1635
  }
1586
- *ptr = SWIG_TypeCast(tc, vptr);
1587
1636
  } else {
1588
1637
  *ptr = vptr;
1589
1638
  }
@@ -1761,7 +1810,7 @@ static VALUE mRlibmemcached;
1761
1810
  #define SWIG_RUBY_THREAD_END_BLOCK
1762
1811
 
1763
1812
 
1764
- #define SWIGVERSION 0x010333
1813
+ #define SWIGVERSION 0x010336
1765
1814
  #define SWIG_VERSION SWIGVERSION
1766
1815
 
1767
1816
 
@@ -1919,7 +1968,7 @@ SWIG_ruby_failed(void)
1919
1968
  }
1920
1969
 
1921
1970
 
1922
- /*@SWIG:/opt/local/share/swig/1.3.33/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
1971
+ /*@SWIG:/opt/local/share/swig/1.3.36/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
1923
1972
  SWIGINTERN VALUE SWIG_AUX_NUM2LONG(VALUE *args)
1924
1973
  {
1925
1974
  VALUE obj = args[0];
@@ -1964,7 +2013,7 @@ SWIG_AsVal_int (VALUE obj, int *val)
1964
2013
  }
1965
2014
 
1966
2015
 
1967
- /*@SWIG:/opt/local/share/swig/1.3.33/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
2016
+ /*@SWIG:/opt/local/share/swig/1.3.36/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
1968
2017
  SWIGINTERN VALUE SWIG_AUX_NUM2ULONG(VALUE *args)
1969
2018
  {
1970
2019
  VALUE obj = args[0];
@@ -2023,9 +2072,6 @@ SWIG_From_unsigned_SS_int (unsigned int value)
2023
2072
  }
2024
2073
 
2025
2074
 
2026
-
2027
-
2028
-
2029
2075
  SWIGINTERNINLINE int
2030
2076
  SWIG_AsVal_size_t (VALUE obj, size_t *val)
2031
2077
  {
@@ -2036,6 +2082,16 @@ SWIG_AsVal_size_t (VALUE obj, size_t *val)
2036
2082
  }
2037
2083
 
2038
2084
 
2085
+ SWIGINTERNINLINE VALUE
2086
+ SWIG_From_size_t (size_t value)
2087
+ {
2088
+ return SWIG_From_unsigned_SS_long ((unsigned long)(value));
2089
+ }
2090
+
2091
+
2092
+
2093
+
2094
+
2039
2095
  SWIGINTERNINLINE VALUE
2040
2096
  SWIG_From_long_SS_long (long long value)
2041
2097
  {
@@ -2057,7 +2113,7 @@ SWIG_From_unsigned_SS_short (unsigned short value)
2057
2113
  }
2058
2114
 
2059
2115
 
2060
- /*@SWIG:/opt/local/share/swig/1.3.33/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
2116
+ /*@SWIG:/opt/local/share/swig/1.3.36/ruby/rubyprimtypes.swg,23,%ruby_aux_method@*/
2061
2117
  SWIGINTERN VALUE SWIG_AUX_NUM2ULL(VALUE *args)
2062
2118
  {
2063
2119
  VALUE obj = args[0];
@@ -2086,13 +2142,6 @@ SWIG_AsVal_unsigned_SS_long_SS_long (VALUE obj, unsigned long long *val)
2086
2142
  }
2087
2143
 
2088
2144
 
2089
- SWIGINTERNINLINE VALUE
2090
- SWIG_From_size_t (size_t value)
2091
- {
2092
- return SWIG_From_unsigned_SS_long ((unsigned long)(value));
2093
- }
2094
-
2095
-
2096
2145
  SWIGINTERN int
2097
2146
  SWIG_AsVal_unsigned_SS_short (VALUE obj, unsigned short *val)
2098
2147
  {
@@ -2109,27 +2158,7 @@ SWIG_AsVal_unsigned_SS_short (VALUE obj, unsigned short *val)
2109
2158
  }
2110
2159
 
2111
2160
 
2112
- VALUE ns(char *namespace, size_t namespace_length, char *key, size_t key_length) {
2113
- char namespaced_key[250];
2114
- size_t namespaced_key_length = namespace_length + key_length;
2115
-
2116
- if (namespaced_key_length > 250)
2117
- namespaced_key_length = 250;
2118
-
2119
- strncpy(namespaced_key, namespace, namespace_length);
2120
- strncpy(namespaced_key + namespace_length, key, namespaced_key_length - namespace_length);
2121
-
2122
- int i;
2123
- for (i = 0; i < namespaced_key_length; i++)
2124
- if ((namespaced_key[i] < 33) || (namespaced_key[i] > 126))
2125
- // Outside printable range
2126
- namespaced_key[i] = '_';
2127
-
2128
- return rb_str_new(namespaced_key, namespaced_key_length);
2129
- };
2130
-
2131
-
2132
- VALUE memcached_get_rvalue(memcached_st *ptr, char *key, size_t key_length, uint32_t *flags, memcached_return *error) {
2161
+ VALUE memcached_get_rvalue(memcached_st *ptr, const char *key, size_t key_length, uint32_t *flags, memcached_return *error) {
2133
2162
  VALUE ret;
2134
2163
  size_t value_length;
2135
2164
  char *value = memcached_get(ptr, key, key_length, &value_length, flags, error);
@@ -2205,7 +2234,6 @@ _wrap_MemcachedContinuumItemSt_index_set(int argc, VALUE *argv, VALUE self) {
2205
2234
  }
2206
2235
  }
2207
2236
  if (arg1) (arg1)->index = arg2;
2208
-
2209
2237
  return Qnil;
2210
2238
  fail:
2211
2239
  return Qnil;
@@ -2215,9 +2243,9 @@ fail:
2215
2243
  SWIGINTERN VALUE
2216
2244
  _wrap_MemcachedContinuumItemSt_index_get(int argc, VALUE *argv, VALUE self) {
2217
2245
  struct memcached_continuum_item_st *arg1 = (struct memcached_continuum_item_st *) 0 ;
2218
- uint32_t result;
2219
2246
  void *argp1 = 0 ;
2220
2247
  int res1 = 0 ;
2248
+ uint32_t result;
2221
2249
  VALUE vresult = Qnil;
2222
2250
 
2223
2251
  if ((argc < 0) || (argc > 0)) {
@@ -2265,7 +2293,6 @@ _wrap_MemcachedContinuumItemSt_value_set(int argc, VALUE *argv, VALUE self) {
2265
2293
  }
2266
2294
  }
2267
2295
  if (arg1) (arg1)->value = arg2;
2268
-
2269
2296
  return Qnil;
2270
2297
  fail:
2271
2298
  return Qnil;
@@ -2275,9 +2302,9 @@ fail:
2275
2302
  SWIGINTERN VALUE
2276
2303
  _wrap_MemcachedContinuumItemSt_value_get(int argc, VALUE *argv, VALUE self) {
2277
2304
  struct memcached_continuum_item_st *arg1 = (struct memcached_continuum_item_st *) 0 ;
2278
- uint32_t result;
2279
2305
  void *argp1 = 0 ;
2280
2306
  int res1 = 0 ;
2307
+ uint32_t result;
2281
2308
  VALUE vresult = Qnil;
2282
2309
 
2283
2310
  if ((argc < 0) || (argc > 0)) {
@@ -2320,8 +2347,8 @@ _wrap_new_MemcachedContinuumItemSt(int argc, VALUE *argv, VALUE self) {
2320
2347
  if ((argc < 0) || (argc > 0)) {
2321
2348
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
2322
2349
  }
2323
- result = (struct memcached_continuum_item_st *)(struct memcached_continuum_item_st *) calloc(1, sizeof(struct memcached_continuum_item_st));DATA_PTR(self) = result;
2324
-
2350
+ result = (struct memcached_continuum_item_st *)calloc(1, sizeof(struct memcached_continuum_item_st));
2351
+ DATA_PTR(self) = result;
2325
2352
  return self;
2326
2353
  fail:
2327
2354
  return Qnil;
@@ -2364,7 +2391,6 @@ _wrap_MemcachedStatSt_pid_set(int argc, VALUE *argv, VALUE self) {
2364
2391
  }
2365
2392
  }
2366
2393
  if (arg1) (arg1)->pid = arg2;
2367
-
2368
2394
  return Qnil;
2369
2395
  fail:
2370
2396
  return Qnil;
@@ -2374,9 +2400,9 @@ fail:
2374
2400
  SWIGINTERN VALUE
2375
2401
  _wrap_MemcachedStatSt_pid_get(int argc, VALUE *argv, VALUE self) {
2376
2402
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2377
- uint32_t result;
2378
2403
  void *argp1 = 0 ;
2379
2404
  int res1 = 0 ;
2405
+ uint32_t result;
2380
2406
  VALUE vresult = Qnil;
2381
2407
 
2382
2408
  if ((argc < 0) || (argc > 0)) {
@@ -2424,7 +2450,6 @@ _wrap_MemcachedStatSt_uptime_set(int argc, VALUE *argv, VALUE self) {
2424
2450
  }
2425
2451
  }
2426
2452
  if (arg1) (arg1)->uptime = arg2;
2427
-
2428
2453
  return Qnil;
2429
2454
  fail:
2430
2455
  return Qnil;
@@ -2434,9 +2459,9 @@ fail:
2434
2459
  SWIGINTERN VALUE
2435
2460
  _wrap_MemcachedStatSt_uptime_get(int argc, VALUE *argv, VALUE self) {
2436
2461
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2437
- uint32_t result;
2438
2462
  void *argp1 = 0 ;
2439
2463
  int res1 = 0 ;
2464
+ uint32_t result;
2440
2465
  VALUE vresult = Qnil;
2441
2466
 
2442
2467
  if ((argc < 0) || (argc > 0)) {
@@ -2484,7 +2509,6 @@ _wrap_MemcachedStatSt_threads_set(int argc, VALUE *argv, VALUE self) {
2484
2509
  }
2485
2510
  }
2486
2511
  if (arg1) (arg1)->threads = arg2;
2487
-
2488
2512
  return Qnil;
2489
2513
  fail:
2490
2514
  return Qnil;
@@ -2494,9 +2518,9 @@ fail:
2494
2518
  SWIGINTERN VALUE
2495
2519
  _wrap_MemcachedStatSt_threads_get(int argc, VALUE *argv, VALUE self) {
2496
2520
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2497
- uint32_t result;
2498
2521
  void *argp1 = 0 ;
2499
2522
  int res1 = 0 ;
2523
+ uint32_t result;
2500
2524
  VALUE vresult = Qnil;
2501
2525
 
2502
2526
  if ((argc < 0) || (argc > 0)) {
@@ -2544,7 +2568,6 @@ _wrap_MemcachedStatSt_time_set(int argc, VALUE *argv, VALUE self) {
2544
2568
  }
2545
2569
  }
2546
2570
  if (arg1) (arg1)->time = arg2;
2547
-
2548
2571
  return Qnil;
2549
2572
  fail:
2550
2573
  return Qnil;
@@ -2554,9 +2577,9 @@ fail:
2554
2577
  SWIGINTERN VALUE
2555
2578
  _wrap_MemcachedStatSt_time_get(int argc, VALUE *argv, VALUE self) {
2556
2579
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2557
- uint32_t result;
2558
2580
  void *argp1 = 0 ;
2559
2581
  int res1 = 0 ;
2582
+ uint32_t result;
2560
2583
  VALUE vresult = Qnil;
2561
2584
 
2562
2585
  if ((argc < 0) || (argc > 0)) {
@@ -2604,7 +2627,6 @@ _wrap_MemcachedStatSt_pointer_size_set(int argc, VALUE *argv, VALUE self) {
2604
2627
  }
2605
2628
  }
2606
2629
  if (arg1) (arg1)->pointer_size = arg2;
2607
-
2608
2630
  return Qnil;
2609
2631
  fail:
2610
2632
  return Qnil;
@@ -2614,9 +2636,9 @@ fail:
2614
2636
  SWIGINTERN VALUE
2615
2637
  _wrap_MemcachedStatSt_pointer_size_get(int argc, VALUE *argv, VALUE self) {
2616
2638
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2617
- uint32_t result;
2618
2639
  void *argp1 = 0 ;
2619
2640
  int res1 = 0 ;
2641
+ uint32_t result;
2620
2642
  VALUE vresult = Qnil;
2621
2643
 
2622
2644
  if ((argc < 0) || (argc > 0)) {
@@ -2664,7 +2686,6 @@ _wrap_MemcachedStatSt_rusage_user_seconds_set(int argc, VALUE *argv, VALUE self)
2664
2686
  }
2665
2687
  }
2666
2688
  if (arg1) (arg1)->rusage_user_seconds = arg2;
2667
-
2668
2689
  return Qnil;
2669
2690
  fail:
2670
2691
  return Qnil;
@@ -2674,9 +2695,9 @@ fail:
2674
2695
  SWIGINTERN VALUE
2675
2696
  _wrap_MemcachedStatSt_rusage_user_seconds_get(int argc, VALUE *argv, VALUE self) {
2676
2697
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2677
- uint32_t result;
2678
2698
  void *argp1 = 0 ;
2679
2699
  int res1 = 0 ;
2700
+ uint32_t result;
2680
2701
  VALUE vresult = Qnil;
2681
2702
 
2682
2703
  if ((argc < 0) || (argc > 0)) {
@@ -2724,7 +2745,6 @@ _wrap_MemcachedStatSt_rusage_user_microseconds_set(int argc, VALUE *argv, VALUE
2724
2745
  }
2725
2746
  }
2726
2747
  if (arg1) (arg1)->rusage_user_microseconds = arg2;
2727
-
2728
2748
  return Qnil;
2729
2749
  fail:
2730
2750
  return Qnil;
@@ -2734,9 +2754,9 @@ fail:
2734
2754
  SWIGINTERN VALUE
2735
2755
  _wrap_MemcachedStatSt_rusage_user_microseconds_get(int argc, VALUE *argv, VALUE self) {
2736
2756
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2737
- uint32_t result;
2738
2757
  void *argp1 = 0 ;
2739
2758
  int res1 = 0 ;
2759
+ uint32_t result;
2740
2760
  VALUE vresult = Qnil;
2741
2761
 
2742
2762
  if ((argc < 0) || (argc > 0)) {
@@ -2784,7 +2804,6 @@ _wrap_MemcachedStatSt_rusage_system_seconds_set(int argc, VALUE *argv, VALUE sel
2784
2804
  }
2785
2805
  }
2786
2806
  if (arg1) (arg1)->rusage_system_seconds = arg2;
2787
-
2788
2807
  return Qnil;
2789
2808
  fail:
2790
2809
  return Qnil;
@@ -2794,9 +2813,9 @@ fail:
2794
2813
  SWIGINTERN VALUE
2795
2814
  _wrap_MemcachedStatSt_rusage_system_seconds_get(int argc, VALUE *argv, VALUE self) {
2796
2815
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2797
- uint32_t result;
2798
2816
  void *argp1 = 0 ;
2799
2817
  int res1 = 0 ;
2818
+ uint32_t result;
2800
2819
  VALUE vresult = Qnil;
2801
2820
 
2802
2821
  if ((argc < 0) || (argc > 0)) {
@@ -2844,7 +2863,6 @@ _wrap_MemcachedStatSt_rusage_system_microseconds_set(int argc, VALUE *argv, VALU
2844
2863
  }
2845
2864
  }
2846
2865
  if (arg1) (arg1)->rusage_system_microseconds = arg2;
2847
-
2848
2866
  return Qnil;
2849
2867
  fail:
2850
2868
  return Qnil;
@@ -2854,9 +2872,9 @@ fail:
2854
2872
  SWIGINTERN VALUE
2855
2873
  _wrap_MemcachedStatSt_rusage_system_microseconds_get(int argc, VALUE *argv, VALUE self) {
2856
2874
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2857
- uint32_t result;
2858
2875
  void *argp1 = 0 ;
2859
2876
  int res1 = 0 ;
2877
+ uint32_t result;
2860
2878
  VALUE vresult = Qnil;
2861
2879
 
2862
2880
  if ((argc < 0) || (argc > 0)) {
@@ -2904,7 +2922,6 @@ _wrap_MemcachedStatSt_curr_items_set(int argc, VALUE *argv, VALUE self) {
2904
2922
  }
2905
2923
  }
2906
2924
  if (arg1) (arg1)->curr_items = arg2;
2907
-
2908
2925
  return Qnil;
2909
2926
  fail:
2910
2927
  return Qnil;
@@ -2914,9 +2931,9 @@ fail:
2914
2931
  SWIGINTERN VALUE
2915
2932
  _wrap_MemcachedStatSt_curr_items_get(int argc, VALUE *argv, VALUE self) {
2916
2933
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2917
- uint32_t result;
2918
2934
  void *argp1 = 0 ;
2919
2935
  int res1 = 0 ;
2936
+ uint32_t result;
2920
2937
  VALUE vresult = Qnil;
2921
2938
 
2922
2939
  if ((argc < 0) || (argc > 0)) {
@@ -2964,7 +2981,6 @@ _wrap_MemcachedStatSt_total_items_set(int argc, VALUE *argv, VALUE self) {
2964
2981
  }
2965
2982
  }
2966
2983
  if (arg1) (arg1)->total_items = arg2;
2967
-
2968
2984
  return Qnil;
2969
2985
  fail:
2970
2986
  return Qnil;
@@ -2974,9 +2990,9 @@ fail:
2974
2990
  SWIGINTERN VALUE
2975
2991
  _wrap_MemcachedStatSt_total_items_get(int argc, VALUE *argv, VALUE self) {
2976
2992
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
2977
- uint32_t result;
2978
2993
  void *argp1 = 0 ;
2979
2994
  int res1 = 0 ;
2995
+ uint32_t result;
2980
2996
  VALUE vresult = Qnil;
2981
2997
 
2982
2998
  if ((argc < 0) || (argc > 0)) {
@@ -3024,7 +3040,6 @@ _wrap_MemcachedStatSt_limit_maxbytes_set(int argc, VALUE *argv, VALUE self) {
3024
3040
  }
3025
3041
  }
3026
3042
  if (arg1) (arg1)->limit_maxbytes = arg2;
3027
-
3028
3043
  return Qnil;
3029
3044
  fail:
3030
3045
  return Qnil;
@@ -3034,9 +3049,9 @@ fail:
3034
3049
  SWIGINTERN VALUE
3035
3050
  _wrap_MemcachedStatSt_limit_maxbytes_get(int argc, VALUE *argv, VALUE self) {
3036
3051
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3037
- uint64_t result;
3038
3052
  void *argp1 = 0 ;
3039
3053
  int res1 = 0 ;
3054
+ uint64_t result;
3040
3055
  VALUE vresult = Qnil;
3041
3056
 
3042
3057
  if ((argc < 0) || (argc > 0)) {
@@ -3086,7 +3101,6 @@ _wrap_MemcachedStatSt_curr_connections_set(int argc, VALUE *argv, VALUE self) {
3086
3101
  }
3087
3102
  }
3088
3103
  if (arg1) (arg1)->curr_connections = arg2;
3089
-
3090
3104
  return Qnil;
3091
3105
  fail:
3092
3106
  return Qnil;
@@ -3096,9 +3110,9 @@ fail:
3096
3110
  SWIGINTERN VALUE
3097
3111
  _wrap_MemcachedStatSt_curr_connections_get(int argc, VALUE *argv, VALUE self) {
3098
3112
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3099
- uint32_t result;
3100
3113
  void *argp1 = 0 ;
3101
3114
  int res1 = 0 ;
3115
+ uint32_t result;
3102
3116
  VALUE vresult = Qnil;
3103
3117
 
3104
3118
  if ((argc < 0) || (argc > 0)) {
@@ -3146,7 +3160,6 @@ _wrap_MemcachedStatSt_total_connections_set(int argc, VALUE *argv, VALUE self) {
3146
3160
  }
3147
3161
  }
3148
3162
  if (arg1) (arg1)->total_connections = arg2;
3149
-
3150
3163
  return Qnil;
3151
3164
  fail:
3152
3165
  return Qnil;
@@ -3156,9 +3169,9 @@ fail:
3156
3169
  SWIGINTERN VALUE
3157
3170
  _wrap_MemcachedStatSt_total_connections_get(int argc, VALUE *argv, VALUE self) {
3158
3171
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3159
- uint32_t result;
3160
3172
  void *argp1 = 0 ;
3161
3173
  int res1 = 0 ;
3174
+ uint32_t result;
3162
3175
  VALUE vresult = Qnil;
3163
3176
 
3164
3177
  if ((argc < 0) || (argc > 0)) {
@@ -3206,7 +3219,6 @@ _wrap_MemcachedStatSt_connection_structures_set(int argc, VALUE *argv, VALUE sel
3206
3219
  }
3207
3220
  }
3208
3221
  if (arg1) (arg1)->connection_structures = arg2;
3209
-
3210
3222
  return Qnil;
3211
3223
  fail:
3212
3224
  return Qnil;
@@ -3216,9 +3228,9 @@ fail:
3216
3228
  SWIGINTERN VALUE
3217
3229
  _wrap_MemcachedStatSt_connection_structures_get(int argc, VALUE *argv, VALUE self) {
3218
3230
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3219
- uint32_t result;
3220
3231
  void *argp1 = 0 ;
3221
3232
  int res1 = 0 ;
3233
+ uint32_t result;
3222
3234
  VALUE vresult = Qnil;
3223
3235
 
3224
3236
  if ((argc < 0) || (argc > 0)) {
@@ -3266,7 +3278,6 @@ _wrap_MemcachedStatSt_bytes_set(int argc, VALUE *argv, VALUE self) {
3266
3278
  }
3267
3279
  }
3268
3280
  if (arg1) (arg1)->bytes = arg2;
3269
-
3270
3281
  return Qnil;
3271
3282
  fail:
3272
3283
  return Qnil;
@@ -3276,9 +3287,9 @@ fail:
3276
3287
  SWIGINTERN VALUE
3277
3288
  _wrap_MemcachedStatSt_bytes_get(int argc, VALUE *argv, VALUE self) {
3278
3289
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3279
- uint64_t result;
3280
3290
  void *argp1 = 0 ;
3281
3291
  int res1 = 0 ;
3292
+ uint64_t result;
3282
3293
  VALUE vresult = Qnil;
3283
3294
 
3284
3295
  if ((argc < 0) || (argc > 0)) {
@@ -3328,7 +3339,6 @@ _wrap_MemcachedStatSt_cmd_get_set(int argc, VALUE *argv, VALUE self) {
3328
3339
  }
3329
3340
  }
3330
3341
  if (arg1) (arg1)->cmd_get = arg2;
3331
-
3332
3342
  return Qnil;
3333
3343
  fail:
3334
3344
  return Qnil;
@@ -3338,9 +3348,9 @@ fail:
3338
3348
  SWIGINTERN VALUE
3339
3349
  _wrap_MemcachedStatSt_cmd_get_get(int argc, VALUE *argv, VALUE self) {
3340
3350
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3341
- uint64_t result;
3342
3351
  void *argp1 = 0 ;
3343
3352
  int res1 = 0 ;
3353
+ uint64_t result;
3344
3354
  VALUE vresult = Qnil;
3345
3355
 
3346
3356
  if ((argc < 0) || (argc > 0)) {
@@ -3390,7 +3400,6 @@ _wrap_MemcachedStatSt_cmd_set_set(int argc, VALUE *argv, VALUE self) {
3390
3400
  }
3391
3401
  }
3392
3402
  if (arg1) (arg1)->cmd_set = arg2;
3393
-
3394
3403
  return Qnil;
3395
3404
  fail:
3396
3405
  return Qnil;
@@ -3400,9 +3409,9 @@ fail:
3400
3409
  SWIGINTERN VALUE
3401
3410
  _wrap_MemcachedStatSt_cmd_set_get(int argc, VALUE *argv, VALUE self) {
3402
3411
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3403
- uint64_t result;
3404
3412
  void *argp1 = 0 ;
3405
3413
  int res1 = 0 ;
3414
+ uint64_t result;
3406
3415
  VALUE vresult = Qnil;
3407
3416
 
3408
3417
  if ((argc < 0) || (argc > 0)) {
@@ -3452,7 +3461,6 @@ _wrap_MemcachedStatSt_get_hits_set(int argc, VALUE *argv, VALUE self) {
3452
3461
  }
3453
3462
  }
3454
3463
  if (arg1) (arg1)->get_hits = arg2;
3455
-
3456
3464
  return Qnil;
3457
3465
  fail:
3458
3466
  return Qnil;
@@ -3462,9 +3470,9 @@ fail:
3462
3470
  SWIGINTERN VALUE
3463
3471
  _wrap_MemcachedStatSt_get_hits_get(int argc, VALUE *argv, VALUE self) {
3464
3472
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3465
- uint64_t result;
3466
3473
  void *argp1 = 0 ;
3467
3474
  int res1 = 0 ;
3475
+ uint64_t result;
3468
3476
  VALUE vresult = Qnil;
3469
3477
 
3470
3478
  if ((argc < 0) || (argc > 0)) {
@@ -3514,7 +3522,6 @@ _wrap_MemcachedStatSt_get_misses_set(int argc, VALUE *argv, VALUE self) {
3514
3522
  }
3515
3523
  }
3516
3524
  if (arg1) (arg1)->get_misses = arg2;
3517
-
3518
3525
  return Qnil;
3519
3526
  fail:
3520
3527
  return Qnil;
@@ -3524,9 +3531,9 @@ fail:
3524
3531
  SWIGINTERN VALUE
3525
3532
  _wrap_MemcachedStatSt_get_misses_get(int argc, VALUE *argv, VALUE self) {
3526
3533
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3527
- uint64_t result;
3528
3534
  void *argp1 = 0 ;
3529
3535
  int res1 = 0 ;
3536
+ uint64_t result;
3530
3537
  VALUE vresult = Qnil;
3531
3538
 
3532
3539
  if ((argc < 0) || (argc > 0)) {
@@ -3576,7 +3583,6 @@ _wrap_MemcachedStatSt_evictions_set(int argc, VALUE *argv, VALUE self) {
3576
3583
  }
3577
3584
  }
3578
3585
  if (arg1) (arg1)->evictions = arg2;
3579
-
3580
3586
  return Qnil;
3581
3587
  fail:
3582
3588
  return Qnil;
@@ -3586,9 +3592,9 @@ fail:
3586
3592
  SWIGINTERN VALUE
3587
3593
  _wrap_MemcachedStatSt_evictions_get(int argc, VALUE *argv, VALUE self) {
3588
3594
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3589
- uint64_t result;
3590
3595
  void *argp1 = 0 ;
3591
3596
  int res1 = 0 ;
3597
+ uint64_t result;
3592
3598
  VALUE vresult = Qnil;
3593
3599
 
3594
3600
  if ((argc < 0) || (argc > 0)) {
@@ -3638,7 +3644,6 @@ _wrap_MemcachedStatSt_bytes_read_set(int argc, VALUE *argv, VALUE self) {
3638
3644
  }
3639
3645
  }
3640
3646
  if (arg1) (arg1)->bytes_read = arg2;
3641
-
3642
3647
  return Qnil;
3643
3648
  fail:
3644
3649
  return Qnil;
@@ -3648,9 +3653,9 @@ fail:
3648
3653
  SWIGINTERN VALUE
3649
3654
  _wrap_MemcachedStatSt_bytes_read_get(int argc, VALUE *argv, VALUE self) {
3650
3655
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3651
- uint64_t result;
3652
3656
  void *argp1 = 0 ;
3653
3657
  int res1 = 0 ;
3658
+ uint64_t result;
3654
3659
  VALUE vresult = Qnil;
3655
3660
 
3656
3661
  if ((argc < 0) || (argc > 0)) {
@@ -3700,7 +3705,6 @@ _wrap_MemcachedStatSt_bytes_written_set(int argc, VALUE *argv, VALUE self) {
3700
3705
  }
3701
3706
  }
3702
3707
  if (arg1) (arg1)->bytes_written = arg2;
3703
-
3704
3708
  return Qnil;
3705
3709
  fail:
3706
3710
  return Qnil;
@@ -3710,9 +3714,9 @@ fail:
3710
3714
  SWIGINTERN VALUE
3711
3715
  _wrap_MemcachedStatSt_bytes_written_get(int argc, VALUE *argv, VALUE self) {
3712
3716
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3713
- uint64_t result;
3714
3717
  void *argp1 = 0 ;
3715
3718
  int res1 = 0 ;
3719
+ uint64_t result;
3716
3720
  VALUE vresult = Qnil;
3717
3721
 
3718
3722
  if ((argc < 0) || (argc > 0)) {
@@ -3766,9 +3770,9 @@ fail:
3766
3770
  SWIGINTERN VALUE
3767
3771
  _wrap_MemcachedStatSt_version_get(int argc, VALUE *argv, VALUE self) {
3768
3772
  struct memcached_stat_st *arg1 = (struct memcached_stat_st *) 0 ;
3769
- char *result = 0 ;
3770
3773
  void *argp1 = 0 ;
3771
3774
  int res1 = 0 ;
3775
+ char *result = 0 ;
3772
3776
  VALUE vresult = Qnil;
3773
3777
 
3774
3778
  if ((argc < 0) || (argc > 0)) {
@@ -3817,8 +3821,8 @@ _wrap_new_MemcachedStatSt(int argc, VALUE *argv, VALUE self) {
3817
3821
  if ((argc < 0) || (argc > 0)) {
3818
3822
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
3819
3823
  }
3820
- result = (struct memcached_stat_st *)(struct memcached_stat_st *) calloc(1, sizeof(struct memcached_stat_st));DATA_PTR(self) = result;
3821
-
3824
+ result = (struct memcached_stat_st *)calloc(1, sizeof(struct memcached_stat_st));
3825
+ DATA_PTR(self) = result;
3822
3826
  return self;
3823
3827
  fail:
3824
3828
  return Qnil;
@@ -3855,7 +3859,6 @@ _wrap_MemcachedSt_is_allocated_set(int argc, VALUE *argv, VALUE self) {
3855
3859
  }
3856
3860
  arg2 = (memcached_allocated)(val2);
3857
3861
  if (arg1) (arg1)->is_allocated = arg2;
3858
-
3859
3862
  return Qnil;
3860
3863
  fail:
3861
3864
  return Qnil;
@@ -3865,9 +3868,9 @@ fail:
3865
3868
  SWIGINTERN VALUE
3866
3869
  _wrap_MemcachedSt_is_allocated_get(int argc, VALUE *argv, VALUE self) {
3867
3870
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
3868
- memcached_allocated result;
3869
3871
  void *argp1 = 0 ;
3870
3872
  int res1 = 0 ;
3873
+ memcached_allocated result;
3871
3874
  VALUE vresult = Qnil;
3872
3875
 
3873
3876
  if ((argc < 0) || (argc > 0)) {
@@ -3909,7 +3912,6 @@ _wrap_MemcachedSt_hosts_set(int argc, VALUE *argv, VALUE self) {
3909
3912
  }
3910
3913
  arg2 = (memcached_server_st *)(argp2);
3911
3914
  if (arg1) (arg1)->hosts = arg2;
3912
-
3913
3915
  return Qnil;
3914
3916
  fail:
3915
3917
  return Qnil;
@@ -3919,9 +3921,9 @@ fail:
3919
3921
  SWIGINTERN VALUE
3920
3922
  _wrap_MemcachedSt_hosts_get(int argc, VALUE *argv, VALUE self) {
3921
3923
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
3922
- memcached_server_st *result = 0 ;
3923
3924
  void *argp1 = 0 ;
3924
3925
  int res1 = 0 ;
3926
+ memcached_server_st *result = 0 ;
3925
3927
  VALUE vresult = Qnil;
3926
3928
 
3927
3929
  if ((argc < 0) || (argc > 0)) {
@@ -3963,7 +3965,6 @@ _wrap_MemcachedSt_number_of_hosts_set(int argc, VALUE *argv, VALUE self) {
3963
3965
  }
3964
3966
  arg2 = (unsigned int)(val2);
3965
3967
  if (arg1) (arg1)->number_of_hosts = arg2;
3966
-
3967
3968
  return Qnil;
3968
3969
  fail:
3969
3970
  return Qnil;
@@ -3973,9 +3974,9 @@ fail:
3973
3974
  SWIGINTERN VALUE
3974
3975
  _wrap_MemcachedSt_number_of_hosts_get(int argc, VALUE *argv, VALUE self) {
3975
3976
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
3976
- unsigned int result;
3977
3977
  void *argp1 = 0 ;
3978
3978
  int res1 = 0 ;
3979
+ unsigned int result;
3979
3980
  VALUE vresult = Qnil;
3980
3981
 
3981
3982
  if ((argc < 0) || (argc > 0)) {
@@ -4017,7 +4018,6 @@ _wrap_MemcachedSt_cursor_server_set(int argc, VALUE *argv, VALUE self) {
4017
4018
  }
4018
4019
  arg2 = (unsigned int)(val2);
4019
4020
  if (arg1) (arg1)->cursor_server = arg2;
4020
-
4021
4021
  return Qnil;
4022
4022
  fail:
4023
4023
  return Qnil;
@@ -4027,9 +4027,9 @@ fail:
4027
4027
  SWIGINTERN VALUE
4028
4028
  _wrap_MemcachedSt_cursor_server_get(int argc, VALUE *argv, VALUE self) {
4029
4029
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4030
- unsigned int result;
4031
4030
  void *argp1 = 0 ;
4032
4031
  int res1 = 0 ;
4032
+ unsigned int result;
4033
4033
  VALUE vresult = Qnil;
4034
4034
 
4035
4035
  if ((argc < 0) || (argc > 0)) {
@@ -4071,7 +4071,6 @@ _wrap_MemcachedSt_cached_errno_set(int argc, VALUE *argv, VALUE self) {
4071
4071
  }
4072
4072
  arg2 = (int)(val2);
4073
4073
  if (arg1) (arg1)->cached_errno = arg2;
4074
-
4075
4074
  return Qnil;
4076
4075
  fail:
4077
4076
  return Qnil;
@@ -4081,9 +4080,9 @@ fail:
4081
4080
  SWIGINTERN VALUE
4082
4081
  _wrap_MemcachedSt_cached_errno_get(int argc, VALUE *argv, VALUE self) {
4083
4082
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4084
- int result;
4085
4083
  void *argp1 = 0 ;
4086
4084
  int res1 = 0 ;
4085
+ int result;
4087
4086
  VALUE vresult = Qnil;
4088
4087
 
4089
4088
  if ((argc < 0) || (argc > 0)) {
@@ -4125,7 +4124,6 @@ _wrap_MemcachedSt_flags_set(int argc, VALUE *argv, VALUE self) {
4125
4124
  }
4126
4125
  arg2 = (uint32_t)(val2);
4127
4126
  if (arg1) (arg1)->flags = arg2;
4128
-
4129
4127
  return Qnil;
4130
4128
  fail:
4131
4129
  return Qnil;
@@ -4135,9 +4133,9 @@ fail:
4135
4133
  SWIGINTERN VALUE
4136
4134
  _wrap_MemcachedSt_flags_get(int argc, VALUE *argv, VALUE self) {
4137
4135
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4138
- uint32_t result;
4139
4136
  void *argp1 = 0 ;
4140
4137
  int res1 = 0 ;
4138
+ uint32_t result;
4141
4139
  VALUE vresult = Qnil;
4142
4140
 
4143
4141
  if ((argc < 0) || (argc > 0)) {
@@ -4179,7 +4177,6 @@ _wrap_MemcachedSt_send_size_set(int argc, VALUE *argv, VALUE self) {
4179
4177
  }
4180
4178
  arg2 = (int)(val2);
4181
4179
  if (arg1) (arg1)->send_size = arg2;
4182
-
4183
4180
  return Qnil;
4184
4181
  fail:
4185
4182
  return Qnil;
@@ -4189,9 +4186,9 @@ fail:
4189
4186
  SWIGINTERN VALUE
4190
4187
  _wrap_MemcachedSt_send_size_get(int argc, VALUE *argv, VALUE self) {
4191
4188
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4192
- int result;
4193
4189
  void *argp1 = 0 ;
4194
4190
  int res1 = 0 ;
4191
+ int result;
4195
4192
  VALUE vresult = Qnil;
4196
4193
 
4197
4194
  if ((argc < 0) || (argc > 0)) {
@@ -4233,7 +4230,6 @@ _wrap_MemcachedSt_recv_size_set(int argc, VALUE *argv, VALUE self) {
4233
4230
  }
4234
4231
  arg2 = (int)(val2);
4235
4232
  if (arg1) (arg1)->recv_size = arg2;
4236
-
4237
4233
  return Qnil;
4238
4234
  fail:
4239
4235
  return Qnil;
@@ -4243,9 +4239,9 @@ fail:
4243
4239
  SWIGINTERN VALUE
4244
4240
  _wrap_MemcachedSt_recv_size_get(int argc, VALUE *argv, VALUE self) {
4245
4241
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4246
- int result;
4247
4242
  void *argp1 = 0 ;
4248
4243
  int res1 = 0 ;
4244
+ int result;
4249
4245
  VALUE vresult = Qnil;
4250
4246
 
4251
4247
  if ((argc < 0) || (argc > 0)) {
@@ -4293,7 +4289,6 @@ _wrap_MemcachedSt_poll_timeout_set(int argc, VALUE *argv, VALUE self) {
4293
4289
  }
4294
4290
  }
4295
4291
  if (arg1) (arg1)->poll_timeout = arg2;
4296
-
4297
4292
  return Qnil;
4298
4293
  fail:
4299
4294
  return Qnil;
@@ -4303,9 +4298,9 @@ fail:
4303
4298
  SWIGINTERN VALUE
4304
4299
  _wrap_MemcachedSt_poll_timeout_get(int argc, VALUE *argv, VALUE self) {
4305
4300
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4306
- int32_t result;
4307
4301
  void *argp1 = 0 ;
4308
4302
  int res1 = 0 ;
4303
+ int32_t result;
4309
4304
  VALUE vresult = Qnil;
4310
4305
 
4311
4306
  if ((argc < 0) || (argc > 0)) {
@@ -4353,7 +4348,6 @@ _wrap_MemcachedSt_connect_timeout_set(int argc, VALUE *argv, VALUE self) {
4353
4348
  }
4354
4349
  }
4355
4350
  if (arg1) (arg1)->connect_timeout = arg2;
4356
-
4357
4351
  return Qnil;
4358
4352
  fail:
4359
4353
  return Qnil;
@@ -4363,9 +4357,9 @@ fail:
4363
4357
  SWIGINTERN VALUE
4364
4358
  _wrap_MemcachedSt_connect_timeout_get(int argc, VALUE *argv, VALUE self) {
4365
4359
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4366
- int32_t result;
4367
4360
  void *argp1 = 0 ;
4368
4361
  int res1 = 0 ;
4362
+ int32_t result;
4369
4363
  VALUE vresult = Qnil;
4370
4364
 
4371
4365
  if ((argc < 0) || (argc > 0)) {
@@ -4413,7 +4407,6 @@ _wrap_MemcachedSt_retry_timeout_set(int argc, VALUE *argv, VALUE self) {
4413
4407
  }
4414
4408
  }
4415
4409
  if (arg1) (arg1)->retry_timeout = arg2;
4416
-
4417
4410
  return Qnil;
4418
4411
  fail:
4419
4412
  return Qnil;
@@ -4423,9 +4416,9 @@ fail:
4423
4416
  SWIGINTERN VALUE
4424
4417
  _wrap_MemcachedSt_retry_timeout_get(int argc, VALUE *argv, VALUE self) {
4425
4418
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4426
- int32_t result;
4427
4419
  void *argp1 = 0 ;
4428
4420
  int res1 = 0 ;
4421
+ int32_t result;
4429
4422
  VALUE vresult = Qnil;
4430
4423
 
4431
4424
  if ((argc < 0) || (argc > 0)) {
@@ -4473,7 +4466,6 @@ _wrap_MemcachedSt_result_set(int argc, VALUE *argv, VALUE self) {
4473
4466
  }
4474
4467
  }
4475
4468
  if (arg1) (arg1)->result = arg2;
4476
-
4477
4469
  return Qnil;
4478
4470
  fail:
4479
4471
  return Qnil;
@@ -4483,9 +4475,9 @@ fail:
4483
4475
  SWIGINTERN VALUE
4484
4476
  _wrap_MemcachedSt_result_get(int argc, VALUE *argv, VALUE self) {
4485
4477
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4486
- memcached_result_st result;
4487
4478
  void *argp1 = 0 ;
4488
4479
  int res1 = 0 ;
4480
+ memcached_result_st result;
4489
4481
  VALUE vresult = Qnil;
4490
4482
 
4491
4483
  if ((argc < 0) || (argc > 0)) {
@@ -4545,7 +4537,6 @@ _wrap_MemcachedSt_hash_set(int argc, VALUE *argv, VALUE self) {
4545
4537
  }
4546
4538
  arg2 = (memcached_hash)(val2);
4547
4539
  if (arg1) (arg1)->hash = arg2;
4548
-
4549
4540
  return Qnil;
4550
4541
  fail:
4551
4542
  return Qnil;
@@ -4555,9 +4546,9 @@ fail:
4555
4546
  SWIGINTERN VALUE
4556
4547
  _wrap_MemcachedSt_hash_get(int argc, VALUE *argv, VALUE self) {
4557
4548
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4558
- memcached_hash result;
4559
4549
  void *argp1 = 0 ;
4560
4550
  int res1 = 0 ;
4551
+ memcached_hash result;
4561
4552
  VALUE vresult = Qnil;
4562
4553
 
4563
4554
  if ((argc < 0) || (argc > 0)) {
@@ -4599,7 +4590,6 @@ _wrap_MemcachedSt_distribution_set(int argc, VALUE *argv, VALUE self) {
4599
4590
  }
4600
4591
  arg2 = (memcached_server_distribution)(val2);
4601
4592
  if (arg1) (arg1)->distribution = arg2;
4602
-
4603
4593
  return Qnil;
4604
4594
  fail:
4605
4595
  return Qnil;
@@ -4609,9 +4599,9 @@ fail:
4609
4599
  SWIGINTERN VALUE
4610
4600
  _wrap_MemcachedSt_distribution_get(int argc, VALUE *argv, VALUE self) {
4611
4601
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4612
- memcached_server_distribution result;
4613
4602
  void *argp1 = 0 ;
4614
4603
  int res1 = 0 ;
4604
+ memcached_server_distribution result;
4615
4605
  VALUE vresult = Qnil;
4616
4606
 
4617
4607
  if ((argc < 0) || (argc > 0)) {
@@ -4651,7 +4641,6 @@ _wrap_MemcachedSt_user_data_set(int argc, VALUE *argv, VALUE self) {
4651
4641
  SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "void *","user_data", 2, argv[0] ));
4652
4642
  }
4653
4643
  if (arg1) (arg1)->user_data = arg2;
4654
-
4655
4644
  return Qnil;
4656
4645
  fail:
4657
4646
  return Qnil;
@@ -4661,9 +4650,9 @@ fail:
4661
4650
  SWIGINTERN VALUE
4662
4651
  _wrap_MemcachedSt_user_data_get(int argc, VALUE *argv, VALUE self) {
4663
4652
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4664
- void *result = 0 ;
4665
4653
  void *argp1 = 0 ;
4666
4654
  int res1 = 0 ;
4655
+ void *result = 0 ;
4667
4656
  VALUE vresult = Qnil;
4668
4657
 
4669
4658
  if ((argc < 0) || (argc > 0)) {
@@ -4705,7 +4694,6 @@ _wrap_MemcachedSt_wheel_set(int argc, VALUE *argv, VALUE self) {
4705
4694
  }
4706
4695
  arg2 = (unsigned int *)(argp2);
4707
4696
  if (arg1) (arg1)->wheel = arg2;
4708
-
4709
4697
  return Qnil;
4710
4698
  fail:
4711
4699
  return Qnil;
@@ -4715,9 +4703,9 @@ fail:
4715
4703
  SWIGINTERN VALUE
4716
4704
  _wrap_MemcachedSt_wheel_get(int argc, VALUE *argv, VALUE self) {
4717
4705
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4718
- unsigned int *result = 0 ;
4719
4706
  void *argp1 = 0 ;
4720
4707
  int res1 = 0 ;
4708
+ unsigned int *result = 0 ;
4721
4709
  VALUE vresult = Qnil;
4722
4710
 
4723
4711
  if ((argc < 0) || (argc > 0)) {
@@ -4765,7 +4753,6 @@ _wrap_MemcachedSt_wheel_count_set(int argc, VALUE *argv, VALUE self) {
4765
4753
  }
4766
4754
  }
4767
4755
  if (arg1) (arg1)->wheel_count = arg2;
4768
-
4769
4756
  return Qnil;
4770
4757
  fail:
4771
4758
  return Qnil;
@@ -4775,9 +4762,9 @@ fail:
4775
4762
  SWIGINTERN VALUE
4776
4763
  _wrap_MemcachedSt_wheel_count_get(int argc, VALUE *argv, VALUE self) {
4777
4764
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4778
- uint32_t result;
4779
4765
  void *argp1 = 0 ;
4780
4766
  int res1 = 0 ;
4767
+ uint32_t result;
4781
4768
  VALUE vresult = Qnil;
4782
4769
 
4783
4770
  if ((argc < 0) || (argc > 0)) {
@@ -4825,7 +4812,6 @@ _wrap_MemcachedSt_continuum_count_set(int argc, VALUE *argv, VALUE self) {
4825
4812
  }
4826
4813
  }
4827
4814
  if (arg1) (arg1)->continuum_count = arg2;
4828
-
4829
4815
  return Qnil;
4830
4816
  fail:
4831
4817
  return Qnil;
@@ -4835,9 +4821,9 @@ fail:
4835
4821
  SWIGINTERN VALUE
4836
4822
  _wrap_MemcachedSt_continuum_count_get(int argc, VALUE *argv, VALUE self) {
4837
4823
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4838
- uint32_t result;
4839
4824
  void *argp1 = 0 ;
4840
4825
  int res1 = 0 ;
4826
+ uint32_t result;
4841
4827
  VALUE vresult = Qnil;
4842
4828
 
4843
4829
  if ((argc < 0) || (argc > 0)) {
@@ -4879,7 +4865,6 @@ _wrap_MemcachedSt_continuum_set(int argc, VALUE *argv, VALUE self) {
4879
4865
  }
4880
4866
  arg2 = (memcached_continuum_item_st *)(argp2);
4881
4867
  if (arg1) (arg1)->continuum = arg2;
4882
-
4883
4868
  return Qnil;
4884
4869
  fail:
4885
4870
  return Qnil;
@@ -4889,9 +4874,9 @@ fail:
4889
4874
  SWIGINTERN VALUE
4890
4875
  _wrap_MemcachedSt_continuum_get(int argc, VALUE *argv, VALUE self) {
4891
4876
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4892
- memcached_continuum_item_st *result = 0 ;
4893
4877
  void *argp1 = 0 ;
4894
4878
  int res1 = 0 ;
4879
+ memcached_continuum_item_st *result = 0 ;
4895
4880
  VALUE vresult = Qnil;
4896
4881
 
4897
4882
  if ((argc < 0) || (argc > 0)) {
@@ -4939,7 +4924,6 @@ _wrap_MemcachedSt_on_clone_set(int argc, VALUE *argv, VALUE self) {
4939
4924
  }
4940
4925
  }
4941
4926
  if (arg1) (arg1)->on_clone = arg2;
4942
-
4943
4927
  return Qnil;
4944
4928
  fail:
4945
4929
  return Qnil;
@@ -4949,9 +4933,9 @@ fail:
4949
4933
  SWIGINTERN VALUE
4950
4934
  _wrap_MemcachedSt_on_clone_get(int argc, VALUE *argv, VALUE self) {
4951
4935
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
4952
- memcached_clone_func result;
4953
4936
  void *argp1 = 0 ;
4954
4937
  int res1 = 0 ;
4938
+ memcached_clone_func result;
4955
4939
  VALUE vresult = Qnil;
4956
4940
 
4957
4941
  if ((argc < 0) || (argc > 0)) {
@@ -4999,7 +4983,6 @@ _wrap_MemcachedSt_on_cleanup_set(int argc, VALUE *argv, VALUE self) {
4999
4983
  }
5000
4984
  }
5001
4985
  if (arg1) (arg1)->on_cleanup = arg2;
5002
-
5003
4986
  return Qnil;
5004
4987
  fail:
5005
4988
  return Qnil;
@@ -5009,9 +4992,9 @@ fail:
5009
4992
  SWIGINTERN VALUE
5010
4993
  _wrap_MemcachedSt_on_cleanup_get(int argc, VALUE *argv, VALUE self) {
5011
4994
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5012
- memcached_cleanup_func result;
5013
4995
  void *argp1 = 0 ;
5014
4996
  int res1 = 0 ;
4997
+ memcached_cleanup_func result;
5015
4998
  VALUE vresult = Qnil;
5016
4999
 
5017
5000
  if ((argc < 0) || (argc > 0)) {
@@ -5059,7 +5042,6 @@ _wrap_MemcachedSt_call_free_set(int argc, VALUE *argv, VALUE self) {
5059
5042
  }
5060
5043
  }
5061
5044
  if (arg1) (arg1)->call_free = arg2;
5062
-
5063
5045
  return Qnil;
5064
5046
  fail:
5065
5047
  return Qnil;
@@ -5069,9 +5051,9 @@ fail:
5069
5051
  SWIGINTERN VALUE
5070
5052
  _wrap_MemcachedSt_call_free_get(int argc, VALUE *argv, VALUE self) {
5071
5053
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5072
- memcached_free_function result;
5073
5054
  void *argp1 = 0 ;
5074
5055
  int res1 = 0 ;
5056
+ memcached_free_function result;
5075
5057
  VALUE vresult = Qnil;
5076
5058
 
5077
5059
  if ((argc < 0) || (argc > 0)) {
@@ -5119,7 +5101,6 @@ _wrap_MemcachedSt_call_malloc_set(int argc, VALUE *argv, VALUE self) {
5119
5101
  }
5120
5102
  }
5121
5103
  if (arg1) (arg1)->call_malloc = arg2;
5122
-
5123
5104
  return Qnil;
5124
5105
  fail:
5125
5106
  return Qnil;
@@ -5129,9 +5110,9 @@ fail:
5129
5110
  SWIGINTERN VALUE
5130
5111
  _wrap_MemcachedSt_call_malloc_get(int argc, VALUE *argv, VALUE self) {
5131
5112
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5132
- memcached_malloc_function result;
5133
5113
  void *argp1 = 0 ;
5134
5114
  int res1 = 0 ;
5115
+ memcached_malloc_function result;
5135
5116
  VALUE vresult = Qnil;
5136
5117
 
5137
5118
  if ((argc < 0) || (argc > 0)) {
@@ -5179,7 +5160,6 @@ _wrap_MemcachedSt_call_realloc_set(int argc, VALUE *argv, VALUE self) {
5179
5160
  }
5180
5161
  }
5181
5162
  if (arg1) (arg1)->call_realloc = arg2;
5182
-
5183
5163
  return Qnil;
5184
5164
  fail:
5185
5165
  return Qnil;
@@ -5189,9 +5169,9 @@ fail:
5189
5169
  SWIGINTERN VALUE
5190
5170
  _wrap_MemcachedSt_call_realloc_get(int argc, VALUE *argv, VALUE self) {
5191
5171
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5192
- memcached_realloc_function result;
5193
5172
  void *argp1 = 0 ;
5194
5173
  int res1 = 0 ;
5174
+ memcached_realloc_function result;
5195
5175
  VALUE vresult = Qnil;
5196
5176
 
5197
5177
  if ((argc < 0) || (argc > 0)) {
@@ -5239,7 +5219,6 @@ _wrap_MemcachedSt_get_key_failure_set(int argc, VALUE *argv, VALUE self) {
5239
5219
  }
5240
5220
  }
5241
5221
  if (arg1) (arg1)->get_key_failure = arg2;
5242
-
5243
5222
  return Qnil;
5244
5223
  fail:
5245
5224
  return Qnil;
@@ -5249,9 +5228,9 @@ fail:
5249
5228
  SWIGINTERN VALUE
5250
5229
  _wrap_MemcachedSt_get_key_failure_get(int argc, VALUE *argv, VALUE self) {
5251
5230
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5252
- memcached_trigger_key result;
5253
5231
  void *argp1 = 0 ;
5254
5232
  int res1 = 0 ;
5233
+ memcached_trigger_key result;
5255
5234
  VALUE vresult = Qnil;
5256
5235
 
5257
5236
  if ((argc < 0) || (argc > 0)) {
@@ -5299,7 +5278,6 @@ _wrap_MemcachedSt_delete_trigger_set(int argc, VALUE *argv, VALUE self) {
5299
5278
  }
5300
5279
  }
5301
5280
  if (arg1) (arg1)->delete_trigger = arg2;
5302
-
5303
5281
  return Qnil;
5304
5282
  fail:
5305
5283
  return Qnil;
@@ -5309,9 +5287,9 @@ fail:
5309
5287
  SWIGINTERN VALUE
5310
5288
  _wrap_MemcachedSt_delete_trigger_get(int argc, VALUE *argv, VALUE self) {
5311
5289
  struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5312
- memcached_trigger_delete_key result;
5313
5290
  void *argp1 = 0 ;
5314
5291
  int res1 = 0 ;
5292
+ memcached_trigger_delete_key result;
5315
5293
  VALUE vresult = Qnil;
5316
5294
 
5317
5295
  if ((argc < 0) || (argc > 0)) {
@@ -5330,65 +5308,173 @@ fail:
5330
5308
  }
5331
5309
 
5332
5310
 
5333
- #ifdef HAVE_RB_DEFINE_ALLOC_FUNC
5334
- SWIGINTERN VALUE
5335
- _wrap_MemcachedSt_allocate(VALUE self) {
5336
- #else
5337
- SWIGINTERN VALUE
5338
- _wrap_MemcachedSt_allocate(int argc, VALUE *argv, VALUE self) {
5339
- #endif
5340
-
5341
-
5342
- VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_memcached_st);
5343
- #ifndef HAVE_RB_DEFINE_ALLOC_FUNC
5344
- rb_obj_call_init(vresult, argc, argv);
5345
- #endif
5346
- return vresult;
5347
- }
5348
-
5349
-
5350
5311
  SWIGINTERN VALUE
5351
- _wrap_new_MemcachedSt(int argc, VALUE *argv, VALUE self) {
5352
- struct memcached_st *result = 0 ;
5312
+ _wrap_MemcachedSt_prefix_key_set(int argc, VALUE *argv, VALUE self) {
5313
+ struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5314
+ char *arg2 ;
5315
+ void *argp1 = 0 ;
5316
+ int res1 = 0 ;
5317
+ char temp2[MEMCACHED_PREFIX_KEY_MAX_SIZE] ;
5318
+ int res2 ;
5353
5319
 
5354
- if ((argc < 0) || (argc > 0)) {
5355
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5320
+ if ((argc < 1) || (argc > 1)) {
5321
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
5356
5322
  }
5357
- result = (struct memcached_st *)(struct memcached_st *) calloc(1, sizeof(struct memcached_st));DATA_PTR(self) = result;
5358
-
5359
- return self;
5323
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5324
+ if (!SWIG_IsOK(res1)) {
5325
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct memcached_st *","prefix_key", 1, self ));
5326
+ }
5327
+ arg1 = (struct memcached_st *)(argp1);
5328
+ res2 = SWIG_AsCharArray(argv[0], temp2, MEMCACHED_PREFIX_KEY_MAX_SIZE);
5329
+ if (!SWIG_IsOK(res2)) {
5330
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char [MEMCACHED_PREFIX_KEY_MAX_SIZE]","prefix_key", 2, argv[0] ));
5331
+ }
5332
+ arg2 = (char *)(temp2);
5333
+ if (arg2) memcpy(arg1->prefix_key,arg2,MEMCACHED_PREFIX_KEY_MAX_SIZE*sizeof(char));
5334
+ else memset(arg1->prefix_key,0,MEMCACHED_PREFIX_KEY_MAX_SIZE*sizeof(char));
5335
+ return Qnil;
5360
5336
  fail:
5361
5337
  return Qnil;
5362
5338
  }
5363
5339
 
5364
5340
 
5365
- SWIGINTERN void
5366
- free_memcached_st(struct memcached_st *arg1) {
5367
- free((char *) arg1);
5368
- }
5369
-
5370
5341
  SWIGINTERN VALUE
5371
- _wrap_memcached_lib_version(int argc, VALUE *argv, VALUE self) {
5342
+ _wrap_MemcachedSt_prefix_key_get(int argc, VALUE *argv, VALUE self) {
5343
+ struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5344
+ void *argp1 = 0 ;
5345
+ int res1 = 0 ;
5372
5346
  char *result = 0 ;
5373
5347
  VALUE vresult = Qnil;
5374
5348
 
5375
5349
  if ((argc < 0) || (argc > 0)) {
5376
5350
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5377
5351
  }
5378
- result = (char *)memcached_lib_version();
5379
- vresult = SWIG_FromCharPtr((const char *)result);
5380
- return vresult;
5381
- fail:
5382
- return Qnil;
5383
- }
5384
-
5352
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5353
+ if (!SWIG_IsOK(res1)) {
5354
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct memcached_st *","prefix_key", 1, self ));
5355
+ }
5356
+ arg1 = (struct memcached_st *)(argp1);
5357
+ result = (char *)(char *) ((arg1)->prefix_key);
5358
+ {
5359
+ size_t size = MEMCACHED_PREFIX_KEY_MAX_SIZE;
5360
+
5361
+ while (size && (result[size - 1] == '\0')) --size;
5362
+
5363
+ vresult = SWIG_FromCharPtrAndSize(result, size);
5364
+ }
5365
+ return vresult;
5366
+ fail:
5367
+ return Qnil;
5368
+ }
5369
+
5370
+
5371
+ SWIGINTERN VALUE
5372
+ _wrap_MemcachedSt_prefix_key_length_set(int argc, VALUE *argv, VALUE self) {
5373
+ struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5374
+ size_t arg2 ;
5375
+ void *argp1 = 0 ;
5376
+ int res1 = 0 ;
5377
+ size_t val2 ;
5378
+ int ecode2 = 0 ;
5379
+
5380
+ if ((argc < 1) || (argc > 1)) {
5381
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
5382
+ }
5383
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5384
+ if (!SWIG_IsOK(res1)) {
5385
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct memcached_st *","prefix_key_length", 1, self ));
5386
+ }
5387
+ arg1 = (struct memcached_st *)(argp1);
5388
+ ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
5389
+ if (!SWIG_IsOK(ecode2)) {
5390
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "size_t","prefix_key_length", 2, argv[0] ));
5391
+ }
5392
+ arg2 = (size_t)(val2);
5393
+ if (arg1) (arg1)->prefix_key_length = arg2;
5394
+ return Qnil;
5395
+ fail:
5396
+ return Qnil;
5397
+ }
5398
+
5399
+
5400
+ SWIGINTERN VALUE
5401
+ _wrap_MemcachedSt_prefix_key_length_get(int argc, VALUE *argv, VALUE self) {
5402
+ struct memcached_st *arg1 = (struct memcached_st *) 0 ;
5403
+ void *argp1 = 0 ;
5404
+ int res1 = 0 ;
5405
+ size_t result;
5406
+ VALUE vresult = Qnil;
5407
+
5408
+ if ((argc < 0) || (argc > 0)) {
5409
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5410
+ }
5411
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5412
+ if (!SWIG_IsOK(res1)) {
5413
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct memcached_st *","prefix_key_length", 1, self ));
5414
+ }
5415
+ arg1 = (struct memcached_st *)(argp1);
5416
+ result = ((arg1)->prefix_key_length);
5417
+ vresult = SWIG_From_size_t((size_t)(result));
5418
+ return vresult;
5419
+ fail:
5420
+ return Qnil;
5421
+ }
5422
+
5423
+
5424
+ #ifdef HAVE_RB_DEFINE_ALLOC_FUNC
5425
+ SWIGINTERN VALUE
5426
+ _wrap_MemcachedSt_allocate(VALUE self) {
5427
+ #else
5428
+ SWIGINTERN VALUE
5429
+ _wrap_MemcachedSt_allocate(int argc, VALUE *argv, VALUE self) {
5430
+ #endif
5431
+
5432
+
5433
+ VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_memcached_st);
5434
+ #ifndef HAVE_RB_DEFINE_ALLOC_FUNC
5435
+ rb_obj_call_init(vresult, argc, argv);
5436
+ #endif
5437
+ return vresult;
5438
+ }
5439
+
5440
+
5441
+ SWIGINTERN VALUE
5442
+ _wrap_new_MemcachedSt(int argc, VALUE *argv, VALUE self) {
5443
+ struct memcached_st *result = 0 ;
5444
+
5445
+ if ((argc < 0) || (argc > 0)) {
5446
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5447
+ }
5448
+ result = (struct memcached_st *)calloc(1, sizeof(struct memcached_st));
5449
+ DATA_PTR(self) = result;
5450
+ return self;
5451
+ fail:
5452
+ return Qnil;
5453
+ }
5454
+
5455
+
5456
+ SWIGINTERN VALUE
5457
+ _wrap_memcached_lib_version(int argc, VALUE *argv, VALUE self) {
5458
+ char *result = 0 ;
5459
+ VALUE vresult = Qnil;
5460
+
5461
+ if ((argc < 0) || (argc > 0)) {
5462
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5463
+ }
5464
+ result = (char *)memcached_lib_version();
5465
+ vresult = SWIG_FromCharPtr((const char *)result);
5466
+ return vresult;
5467
+ fail:
5468
+ return Qnil;
5469
+ }
5470
+
5385
5471
 
5386
5472
  SWIGINTERN VALUE
5387
5473
  _wrap_memcached_create(int argc, VALUE *argv, VALUE self) {
5388
5474
  memcached_st *arg1 = (memcached_st *) 0 ;
5389
- memcached_st *result = 0 ;
5390
5475
  void *argp1 = 0 ;
5391
5476
  int res1 = 0 ;
5477
+ memcached_st *result = 0 ;
5392
5478
  VALUE vresult = Qnil;
5393
5479
 
5394
5480
  if ((argc < 1) || (argc > 1)) {
@@ -5432,11 +5518,11 @@ SWIGINTERN VALUE
5432
5518
  _wrap_memcached_clone(int argc, VALUE *argv, VALUE self) {
5433
5519
  memcached_st *arg1 = (memcached_st *) 0 ;
5434
5520
  memcached_st *arg2 = (memcached_st *) 0 ;
5435
- memcached_st *result = 0 ;
5436
5521
  void *argp1 = 0 ;
5437
5522
  int res1 = 0 ;
5438
5523
  void *argp2 = 0 ;
5439
5524
  int res2 = 0 ;
5525
+ memcached_st *result = 0 ;
5440
5526
  VALUE vresult = Qnil;
5441
5527
 
5442
5528
  if ((argc < 2) || (argc > 2)) {
@@ -5466,9 +5552,9 @@ _wrap_memcached_delete(int argc, VALUE *argv, VALUE self) {
5466
5552
  char *arg2 = (char *) 0 ;
5467
5553
  size_t arg3 ;
5468
5554
  time_t arg4 ;
5469
- memcached_return result;
5470
5555
  void *argp1 = 0 ;
5471
5556
  int res1 = 0 ;
5557
+ memcached_return result;
5472
5558
  VALUE vresult = Qnil;
5473
5559
 
5474
5560
  if ((argc < 3) || (argc > 3)) {
@@ -5489,7 +5575,7 @@ _wrap_memcached_delete(int argc, VALUE *argv, VALUE self) {
5489
5575
  else
5490
5576
  arg4 = NUM2LONG(rb_funcall(argv[2], rb_intern("tv_sec"), 0));
5491
5577
  }
5492
- result = (memcached_return)memcached_delete(arg1,arg2,arg3,arg4);
5578
+ result = (memcached_return)memcached_delete(arg1,(char const *)arg2,arg3,arg4);
5493
5579
  vresult = SWIG_From_int((int)(result));
5494
5580
  return vresult;
5495
5581
  fail:
@@ -5504,13 +5590,13 @@ _wrap_memcached_increment(int argc, VALUE *argv, VALUE self) {
5504
5590
  size_t arg3 ;
5505
5591
  uint32_t arg4 ;
5506
5592
  uint64_t *arg5 = (uint64_t *) 0 ;
5507
- memcached_return result;
5508
5593
  void *argp1 = 0 ;
5509
5594
  int res1 = 0 ;
5510
5595
  unsigned long val4 ;
5511
5596
  int ecode4 = 0 ;
5512
5597
  uint64_t temp5 ;
5513
5598
  int res5 = SWIG_TMPOBJ ;
5599
+ memcached_return result;
5514
5600
  VALUE vresult = Qnil;
5515
5601
 
5516
5602
  arg5 = &temp5;
@@ -5531,7 +5617,7 @@ _wrap_memcached_increment(int argc, VALUE *argv, VALUE self) {
5531
5617
  SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "uint32_t","memcached_increment", 4, argv[2] ));
5532
5618
  }
5533
5619
  arg4 = (uint32_t)(val4);
5534
- result = (memcached_return)memcached_increment(arg1,arg2,arg3,arg4,arg5);
5620
+ result = (memcached_return)memcached_increment(arg1,(char const *)arg2,arg3,arg4,arg5);
5535
5621
  vresult = SWIG_From_int((int)(result));
5536
5622
  if (SWIG_IsTmpObj(res5)) {
5537
5623
  vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_long_SS_long((*arg5)));
@@ -5552,13 +5638,13 @@ _wrap_memcached_decrement(int argc, VALUE *argv, VALUE self) {
5552
5638
  size_t arg3 ;
5553
5639
  uint32_t arg4 ;
5554
5640
  uint64_t *arg5 = (uint64_t *) 0 ;
5555
- memcached_return result;
5556
5641
  void *argp1 = 0 ;
5557
5642
  int res1 = 0 ;
5558
5643
  unsigned long val4 ;
5559
5644
  int ecode4 = 0 ;
5560
5645
  uint64_t temp5 ;
5561
5646
  int res5 = SWIG_TMPOBJ ;
5647
+ memcached_return result;
5562
5648
  VALUE vresult = Qnil;
5563
5649
 
5564
5650
  arg5 = &temp5;
@@ -5579,7 +5665,7 @@ _wrap_memcached_decrement(int argc, VALUE *argv, VALUE self) {
5579
5665
  SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "uint32_t","memcached_decrement", 4, argv[2] ));
5580
5666
  }
5581
5667
  arg4 = (uint32_t)(val4);
5582
- result = (memcached_return)memcached_decrement(arg1,arg2,arg3,arg4,arg5);
5668
+ result = (memcached_return)memcached_decrement(arg1,(char const *)arg2,arg3,arg4,arg5);
5583
5669
  vresult = SWIG_From_int((int)(result));
5584
5670
  if (SWIG_IsTmpObj(res5)) {
5585
5671
  vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_long_SS_long((*arg5)));
@@ -5627,7 +5713,6 @@ _wrap_memcached_stat(int argc, VALUE *argv, VALUE self) {
5627
5713
  memcached_st *arg1 = (memcached_st *) 0 ;
5628
5714
  char *arg2 = (char *) 0 ;
5629
5715
  memcached_return *arg3 = (memcached_return *) 0 ;
5630
- memcached_stat_st *result = 0 ;
5631
5716
  void *argp1 = 0 ;
5632
5717
  int res1 = 0 ;
5633
5718
  int res2 ;
@@ -5635,6 +5720,7 @@ _wrap_memcached_stat(int argc, VALUE *argv, VALUE self) {
5635
5720
  int alloc2 = 0 ;
5636
5721
  memcached_return temp3 ;
5637
5722
  int res3 = SWIG_TMPOBJ ;
5723
+ memcached_stat_st *result = 0 ;
5638
5724
  VALUE vresult = Qnil;
5639
5725
 
5640
5726
  arg3 = &temp3;
@@ -5673,7 +5759,6 @@ _wrap_memcached_stat_servername(int argc, VALUE *argv, VALUE self) {
5673
5759
  char *arg2 = (char *) 0 ;
5674
5760
  char *arg3 = (char *) 0 ;
5675
5761
  unsigned int arg4 ;
5676
- memcached_return result;
5677
5762
  void *argp1 = 0 ;
5678
5763
  int res1 = 0 ;
5679
5764
  int res2 ;
@@ -5684,6 +5769,7 @@ _wrap_memcached_stat_servername(int argc, VALUE *argv, VALUE self) {
5684
5769
  int alloc3 = 0 ;
5685
5770
  unsigned int val4 ;
5686
5771
  int ecode4 = 0 ;
5772
+ memcached_return result;
5687
5773
  VALUE vresult = Qnil;
5688
5774
 
5689
5775
  if ((argc < 4) || (argc > 4)) {
@@ -5725,9 +5811,9 @@ SWIGINTERN VALUE
5725
5811
  _wrap_memcached_flush(int argc, VALUE *argv, VALUE self) {
5726
5812
  memcached_st *arg1 = (memcached_st *) 0 ;
5727
5813
  time_t arg2 ;
5728
- memcached_return result;
5729
5814
  void *argp1 = 0 ;
5730
5815
  int res1 = 0 ;
5816
+ memcached_return result;
5731
5817
  VALUE vresult = Qnil;
5732
5818
 
5733
5819
  if ((argc < 2) || (argc > 2)) {
@@ -5756,11 +5842,11 @@ SWIGINTERN VALUE
5756
5842
  _wrap_memcached_verbosity(int argc, VALUE *argv, VALUE self) {
5757
5843
  memcached_st *arg1 = (memcached_st *) 0 ;
5758
5844
  unsigned int arg2 ;
5759
- memcached_return result;
5760
5845
  void *argp1 = 0 ;
5761
5846
  int res1 = 0 ;
5762
5847
  unsigned int val2 ;
5763
5848
  int ecode2 = 0 ;
5849
+ memcached_return result;
5764
5850
  VALUE vresult = Qnil;
5765
5851
 
5766
5852
  if ((argc < 2) || (argc > 2)) {
@@ -5809,11 +5895,11 @@ SWIGINTERN VALUE
5809
5895
  _wrap_memcached_strerror(int argc, VALUE *argv, VALUE self) {
5810
5896
  memcached_st *arg1 = (memcached_st *) 0 ;
5811
5897
  memcached_return arg2 ;
5812
- char *result = 0 ;
5813
5898
  void *argp1 = 0 ;
5814
5899
  int res1 = 0 ;
5815
5900
  int val2 ;
5816
5901
  int ecode2 = 0 ;
5902
+ char *result = 0 ;
5817
5903
  VALUE vresult = Qnil;
5818
5904
 
5819
5905
  if ((argc < 2) || (argc > 2)) {
@@ -5842,13 +5928,13 @@ _wrap_memcached_behavior_set(int argc, VALUE *argv, VALUE self) {
5842
5928
  memcached_st *arg1 = (memcached_st *) 0 ;
5843
5929
  memcached_behavior arg2 ;
5844
5930
  uint64_t arg3 ;
5845
- memcached_return result;
5846
5931
  void *argp1 = 0 ;
5847
5932
  int res1 = 0 ;
5848
5933
  int val2 ;
5849
5934
  int ecode2 = 0 ;
5850
5935
  unsigned long long val3 ;
5851
5936
  int ecode3 = 0 ;
5937
+ memcached_return result;
5852
5938
  VALUE vresult = Qnil;
5853
5939
 
5854
5940
  if ((argc < 3) || (argc > 3)) {
@@ -5881,11 +5967,11 @@ SWIGINTERN VALUE
5881
5967
  _wrap_memcached_behavior_get(int argc, VALUE *argv, VALUE self) {
5882
5968
  memcached_st *arg1 = (memcached_st *) 0 ;
5883
5969
  memcached_behavior arg2 ;
5884
- uint64_t result;
5885
5970
  void *argp1 = 0 ;
5886
5971
  int res1 = 0 ;
5887
5972
  int val2 ;
5888
5973
  int ecode2 = 0 ;
5974
+ uint64_t result;
5889
5975
  VALUE vresult = Qnil;
5890
5976
 
5891
5977
  if ((argc < 2) || (argc > 2)) {
@@ -5912,74 +5998,58 @@ fail:
5912
5998
 
5913
5999
 
5914
6000
  SWIGINTERN VALUE
5915
- _wrap_memcached_get(int argc, VALUE *argv, VALUE self) {
6001
+ _wrap_memcached_server_add_udp(int argc, VALUE *argv, VALUE self) {
5916
6002
  memcached_st *arg1 = (memcached_st *) 0 ;
5917
6003
  char *arg2 = (char *) 0 ;
5918
- size_t arg3 ;
5919
- size_t *arg4 = (size_t *) 0 ;
5920
- uint32_t *arg5 = (uint32_t *) 0 ;
5921
- memcached_return *arg6 = (memcached_return *) 0 ;
5922
- char *result = 0 ;
6004
+ unsigned int arg3 ;
5923
6005
  void *argp1 = 0 ;
5924
6006
  int res1 = 0 ;
5925
- size_t temp4 ;
5926
- int res4 = SWIG_TMPOBJ ;
5927
- uint32_t temp5 ;
5928
- int res5 = SWIG_TMPOBJ ;
5929
- memcached_return temp6 ;
5930
- int res6 = SWIG_TMPOBJ ;
6007
+ int res2 ;
6008
+ char *buf2 = 0 ;
6009
+ int alloc2 = 0 ;
6010
+ unsigned int val3 ;
6011
+ int ecode3 = 0 ;
6012
+ memcached_return result;
5931
6013
  VALUE vresult = Qnil;
5932
6014
 
5933
- arg4 = &temp4;
5934
- arg5 = &temp5;
5935
- arg6 = &temp6;
5936
- if ((argc < 2) || (argc > 2)) {
5937
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6015
+ if ((argc < 3) || (argc > 3)) {
6016
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
5938
6017
  }
5939
6018
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5940
6019
  if (!SWIG_IsOK(res1)) {
5941
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_get", 1, argv[0] ));
6020
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_add_udp", 1, argv[0] ));
5942
6021
  }
5943
6022
  arg1 = (memcached_st *)(argp1);
5944
- {
5945
- arg2 = STR2CSTR(argv[1]);
5946
- arg3 = (size_t) RSTRING(argv[1])->len;
5947
- }
5948
- result = (char *)memcached_get(arg1,arg2,arg3,arg4,arg5,arg6);
5949
- vresult = SWIG_FromCharPtr((const char *)result);
5950
- if (SWIG_IsTmpObj(res4)) {
5951
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg4)));
5952
- } else {
5953
- int new_flags = SWIG_IsNewObj(res4) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
5954
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg4), SWIGTYPE_p_size_t, new_flags));
5955
- }
5956
- if (SWIG_IsTmpObj(res5)) {
5957
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg5)));
5958
- } else {
5959
- int new_flags = SWIG_IsNewObj(res5) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
5960
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg5), SWIGTYPE_p_uint32_t, new_flags));
5961
- }
5962
- if (SWIG_IsTmpObj(res6)) {
5963
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg6)));
5964
- } else {
5965
- int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
5966
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_memcached_return, new_flags));
6023
+ res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6024
+ if (!SWIG_IsOK(res2)) {
6025
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","memcached_server_add_udp", 2, argv[1] ));
5967
6026
  }
6027
+ arg2 = (char *)(buf2);
6028
+ ecode3 = SWIG_AsVal_unsigned_SS_int(argv[2], &val3);
6029
+ if (!SWIG_IsOK(ecode3)) {
6030
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "unsigned int","memcached_server_add_udp", 3, argv[2] ));
6031
+ }
6032
+ arg3 = (unsigned int)(val3);
6033
+ result = (memcached_return)memcached_server_add_udp(arg1,arg2,arg3);
6034
+ vresult = SWIG_From_int((int)(result));
6035
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
5968
6036
  return vresult;
5969
6037
  fail:
6038
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
5970
6039
  return Qnil;
5971
6040
  }
5972
6041
 
5973
6042
 
5974
6043
  SWIGINTERN VALUE
5975
- _wrap_memcached_mget(int argc, VALUE *argv, VALUE self) {
6044
+ _wrap_memcached_server_add_unix_socket(int argc, VALUE *argv, VALUE self) {
5976
6045
  memcached_st *arg1 = (memcached_st *) 0 ;
5977
- char **arg2 = (char **) 0 ;
5978
- size_t *arg3 = (size_t *) 0 ;
5979
- unsigned int arg4 ;
5980
- memcached_return result;
6046
+ char *arg2 = (char *) 0 ;
5981
6047
  void *argp1 = 0 ;
5982
6048
  int res1 = 0 ;
6049
+ int res2 ;
6050
+ char *buf2 = 0 ;
6051
+ int alloc2 = 0 ;
6052
+ memcached_return result;
5983
6053
  VALUE vresult = Qnil;
5984
6054
 
5985
6055
  if ((argc < 2) || (argc > 2)) {
@@ -5987,235 +6057,37 @@ _wrap_memcached_mget(int argc, VALUE *argv, VALUE self) {
5987
6057
  }
5988
6058
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
5989
6059
  if (!SWIG_IsOK(res1)) {
5990
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_mget", 1, argv[0] ));
6060
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_add_unix_socket", 1, argv[0] ));
5991
6061
  }
5992
6062
  arg1 = (memcached_st *)(argp1);
5993
- {
5994
- int i;
5995
- Check_Type(argv[1], T_ARRAY);
5996
- arg4 = (unsigned int) RARRAY_LEN(argv[1]);
5997
- arg3 = (size_t *) malloc((arg4+1)*sizeof(size_t));
5998
- arg2 = (char **) malloc((arg4+1)*sizeof(char *));
5999
- for(i = 0; i < arg4; i ++) {
6000
- arg3[i] = strlen(StringValuePtr(RARRAY_PTR(argv[1])[i]));
6001
- arg2[i] = StringValuePtr(RARRAY_PTR(argv[1])[i]);
6002
- }
6063
+ res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6064
+ if (!SWIG_IsOK(res2)) {
6065
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","memcached_server_add_unix_socket", 2, argv[1] ));
6003
6066
  }
6004
- result = (memcached_return)memcached_mget(arg1,arg2,arg3,arg4);
6067
+ arg2 = (char *)(buf2);
6068
+ result = (memcached_return)memcached_server_add_unix_socket(arg1,arg2);
6005
6069
  vresult = SWIG_From_int((int)(result));
6006
- {
6007
- free(arg2);
6008
- free(arg3);
6009
- }
6070
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6010
6071
  return vresult;
6011
6072
  fail:
6012
- {
6013
- free(arg2);
6014
- free(arg3);
6015
- }
6073
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6016
6074
  return Qnil;
6017
6075
  }
6018
6076
 
6019
6077
 
6020
6078
  SWIGINTERN VALUE
6021
- _wrap_memcached_fetch(int argc, VALUE *argv, VALUE self) {
6079
+ _wrap_memcached_server_add(int argc, VALUE *argv, VALUE self) {
6022
6080
  memcached_st *arg1 = (memcached_st *) 0 ;
6023
6081
  char *arg2 = (char *) 0 ;
6024
- size_t *arg3 = (size_t *) 0 ;
6025
- size_t *arg4 = (size_t *) 0 ;
6026
- uint32_t *arg5 = (uint32_t *) 0 ;
6027
- memcached_return *arg6 = (memcached_return *) 0 ;
6028
- char *result = 0 ;
6082
+ unsigned int arg3 ;
6029
6083
  void *argp1 = 0 ;
6030
6084
  int res1 = 0 ;
6031
- size_t temp4 ;
6032
- int res4 = SWIG_TMPOBJ ;
6033
- uint32_t temp5 ;
6034
- int res5 = SWIG_TMPOBJ ;
6035
- memcached_return temp6 ;
6036
- int res6 = SWIG_TMPOBJ ;
6037
- VALUE vresult = Qnil;
6038
-
6039
- {
6040
- char string[256];
6041
- size_t length = 0;
6042
- arg2 = string;
6043
- arg3 = &length;
6044
- }
6045
- arg4 = &temp4;
6046
- arg5 = &temp5;
6047
- arg6 = &temp6;
6048
- if ((argc < 1) || (argc > 1)) {
6049
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6050
- }
6051
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6052
- if (!SWIG_IsOK(res1)) {
6053
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch", 1, argv[0] ));
6054
- }
6055
- arg1 = (memcached_st *)(argp1);
6056
- result = (char *)memcached_fetch(arg1,arg2,arg3,arg4,arg5,arg6);
6057
- vresult = SWIG_FromCharPtr((const char *)result);
6058
- {
6059
- // Pushes an empty string when *key_length == 0
6060
- rb_ary_push(vresult, rb_str_new(arg2, *arg3));
6061
- }
6062
- if (SWIG_IsTmpObj(res4)) {
6063
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg4)));
6064
- } else {
6065
- int new_flags = SWIG_IsNewObj(res4) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6066
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg4), SWIGTYPE_p_size_t, new_flags));
6067
- }
6068
- if (SWIG_IsTmpObj(res5)) {
6069
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg5)));
6070
- } else {
6071
- int new_flags = SWIG_IsNewObj(res5) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6072
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg5), SWIGTYPE_p_uint32_t, new_flags));
6073
- }
6074
- if (SWIG_IsTmpObj(res6)) {
6075
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg6)));
6076
- } else {
6077
- int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6078
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_memcached_return, new_flags));
6079
- }
6080
- return vresult;
6081
- fail:
6082
- return Qnil;
6083
- }
6084
-
6085
-
6086
- SWIGINTERN VALUE
6087
- _wrap_memcached_fetch_result(int argc, VALUE *argv, VALUE self) {
6088
- memcached_st *arg1 = (memcached_st *) 0 ;
6089
- memcached_result_st *arg2 = (memcached_result_st *) 0 ;
6090
- memcached_return *arg3 = (memcached_return *) 0 ;
6091
- memcached_result_st *result = 0 ;
6092
- void *argp1 = 0 ;
6093
- int res1 = 0 ;
6094
- void *argp2 = 0 ;
6095
- int res2 = 0 ;
6096
- memcached_return temp3 ;
6097
- int res3 = SWIG_TMPOBJ ;
6098
- VALUE vresult = Qnil;
6099
-
6100
- arg3 = &temp3;
6101
- if ((argc < 2) || (argc > 2)) {
6102
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6103
- }
6104
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6105
- if (!SWIG_IsOK(res1)) {
6106
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch_result", 1, argv[0] ));
6107
- }
6108
- arg1 = (memcached_st *)(argp1);
6109
- res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_result_st, 0 | 0 );
6110
- if (!SWIG_IsOK(res2)) {
6111
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_result_st *","memcached_fetch_result", 2, argv[1] ));
6112
- }
6113
- arg2 = (memcached_result_st *)(argp2);
6114
- result = (memcached_result_st *)memcached_fetch_result(arg1,arg2,arg3);
6115
- vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_memcached_result_st, 0 | 0 );
6116
- if (SWIG_IsTmpObj(res3)) {
6117
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg3)));
6118
- } else {
6119
- int new_flags = SWIG_IsNewObj(res3) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6120
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg3), SWIGTYPE_p_memcached_return, new_flags));
6121
- }
6122
- return vresult;
6123
- fail:
6124
- return Qnil;
6125
- }
6126
-
6127
-
6128
- SWIGINTERN VALUE
6129
- _wrap_memcached_server_add_udp(int argc, VALUE *argv, VALUE self) {
6130
- memcached_st *arg1 = (memcached_st *) 0 ;
6131
- char *arg2 = (char *) 0 ;
6132
- unsigned int arg3 ;
6133
- memcached_return result;
6134
- void *argp1 = 0 ;
6135
- int res1 = 0 ;
6136
- int res2 ;
6137
- char *buf2 = 0 ;
6138
- int alloc2 = 0 ;
6139
- unsigned int val3 ;
6140
- int ecode3 = 0 ;
6141
- VALUE vresult = Qnil;
6142
-
6143
- if ((argc < 3) || (argc > 3)) {
6144
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
6145
- }
6146
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6147
- if (!SWIG_IsOK(res1)) {
6148
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_add_udp", 1, argv[0] ));
6149
- }
6150
- arg1 = (memcached_st *)(argp1);
6151
- res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6152
- if (!SWIG_IsOK(res2)) {
6153
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","memcached_server_add_udp", 2, argv[1] ));
6154
- }
6155
- arg2 = (char *)(buf2);
6156
- ecode3 = SWIG_AsVal_unsigned_SS_int(argv[2], &val3);
6157
- if (!SWIG_IsOK(ecode3)) {
6158
- SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "unsigned int","memcached_server_add_udp", 3, argv[2] ));
6159
- }
6160
- arg3 = (unsigned int)(val3);
6161
- result = (memcached_return)memcached_server_add_udp(arg1,arg2,arg3);
6162
- vresult = SWIG_From_int((int)(result));
6163
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6164
- return vresult;
6165
- fail:
6166
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6167
- return Qnil;
6168
- }
6169
-
6170
-
6171
- SWIGINTERN VALUE
6172
- _wrap_memcached_server_add_unix_socket(int argc, VALUE *argv, VALUE self) {
6173
- memcached_st *arg1 = (memcached_st *) 0 ;
6174
- char *arg2 = (char *) 0 ;
6175
- memcached_return result;
6176
- void *argp1 = 0 ;
6177
- int res1 = 0 ;
6178
- int res2 ;
6179
- char *buf2 = 0 ;
6180
- int alloc2 = 0 ;
6181
- VALUE vresult = Qnil;
6182
-
6183
- if ((argc < 2) || (argc > 2)) {
6184
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6185
- }
6186
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6187
- if (!SWIG_IsOK(res1)) {
6188
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_add_unix_socket", 1, argv[0] ));
6189
- }
6190
- arg1 = (memcached_st *)(argp1);
6191
- res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6192
- if (!SWIG_IsOK(res2)) {
6193
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","memcached_server_add_unix_socket", 2, argv[1] ));
6194
- }
6195
- arg2 = (char *)(buf2);
6196
- result = (memcached_return)memcached_server_add_unix_socket(arg1,arg2);
6197
- vresult = SWIG_From_int((int)(result));
6198
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6199
- return vresult;
6200
- fail:
6201
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6202
- return Qnil;
6203
- }
6204
-
6205
-
6206
- SWIGINTERN VALUE
6207
- _wrap_memcached_server_add(int argc, VALUE *argv, VALUE self) {
6208
- memcached_st *arg1 = (memcached_st *) 0 ;
6209
- char *arg2 = (char *) 0 ;
6210
- unsigned int arg3 ;
6211
- memcached_return result;
6212
- void *argp1 = 0 ;
6213
- int res1 = 0 ;
6214
- int res2 ;
6215
- char *buf2 = 0 ;
6216
- int alloc2 = 0 ;
6217
- unsigned int val3 ;
6218
- int ecode3 = 0 ;
6085
+ int res2 ;
6086
+ char *buf2 = 0 ;
6087
+ int alloc2 = 0 ;
6088
+ unsigned int val3 ;
6089
+ int ecode3 = 0 ;
6090
+ memcached_return result;
6219
6091
  VALUE vresult = Qnil;
6220
6092
 
6221
6093
  if ((argc < 3) || (argc > 3)) {
@@ -6271,11 +6143,11 @@ SWIGINTERN VALUE
6271
6143
  _wrap_memcached_server_push(int argc, VALUE *argv, VALUE self) {
6272
6144
  memcached_st *arg1 = (memcached_st *) 0 ;
6273
6145
  memcached_server_st *arg2 = (memcached_server_st *) 0 ;
6274
- memcached_return result;
6275
6146
  void *argp1 = 0 ;
6276
6147
  int res1 = 0 ;
6277
6148
  void *argp2 = 0 ;
6278
6149
  int res2 = 0 ;
6150
+ memcached_return result;
6279
6151
  VALUE vresult = Qnil;
6280
6152
 
6281
6153
  if ((argc < 2) || (argc > 2)) {
@@ -6305,7 +6177,6 @@ _wrap_memcached_server_list_append(int argc, VALUE *argv, VALUE self) {
6305
6177
  char *arg2 = (char *) 0 ;
6306
6178
  unsigned int arg3 ;
6307
6179
  memcached_return *arg4 = (memcached_return *) 0 ;
6308
- memcached_server_st *result = 0 ;
6309
6180
  void *argp1 = 0 ;
6310
6181
  int res1 = 0 ;
6311
6182
  int res2 ;
@@ -6315,6 +6186,7 @@ _wrap_memcached_server_list_append(int argc, VALUE *argv, VALUE self) {
6315
6186
  int ecode3 = 0 ;
6316
6187
  memcached_return temp4 ;
6317
6188
  int res4 = SWIG_TMPOBJ ;
6189
+ memcached_server_st *result = 0 ;
6318
6190
  VALUE vresult = Qnil;
6319
6191
 
6320
6192
  arg4 = &temp4;
@@ -6355,9 +6227,9 @@ fail:
6355
6227
  SWIGINTERN VALUE
6356
6228
  _wrap_memcached_server_list_count(int argc, VALUE *argv, VALUE self) {
6357
6229
  memcached_server_st *arg1 = (memcached_server_st *) 0 ;
6358
- unsigned int result;
6359
6230
  void *argp1 = 0 ;
6360
6231
  int res1 = 0 ;
6232
+ unsigned int result;
6361
6233
  VALUE vresult = Qnil;
6362
6234
 
6363
6235
  if ((argc < 1) || (argc > 1)) {
@@ -6379,10 +6251,10 @@ fail:
6379
6251
  SWIGINTERN VALUE
6380
6252
  _wrap_memcached_servers_parse(int argc, VALUE *argv, VALUE self) {
6381
6253
  char *arg1 = (char *) 0 ;
6382
- memcached_server_st *result = 0 ;
6383
6254
  int res1 ;
6384
6255
  char *buf1 = 0 ;
6385
6256
  int alloc1 = 0 ;
6257
+ memcached_server_st *result = 0 ;
6386
6258
  VALUE vresult = Qnil;
6387
6259
 
6388
6260
  if ((argc < 1) || (argc > 1)) {
@@ -6409,7 +6281,6 @@ _wrap_memcached_stat_get_value(int argc, VALUE *argv, VALUE self) {
6409
6281
  memcached_stat_st *arg2 = (memcached_stat_st *) 0 ;
6410
6282
  char *arg3 = (char *) 0 ;
6411
6283
  memcached_return *arg4 = (memcached_return *) 0 ;
6412
- char *result = 0 ;
6413
6284
  void *argp1 = 0 ;
6414
6285
  int res1 = 0 ;
6415
6286
  void *argp2 = 0 ;
@@ -6419,6 +6290,7 @@ _wrap_memcached_stat_get_value(int argc, VALUE *argv, VALUE self) {
6419
6290
  int alloc3 = 0 ;
6420
6291
  memcached_return temp4 ;
6421
6292
  int res4 = SWIG_TMPOBJ ;
6293
+ char *result = 0 ;
6422
6294
  VALUE vresult = Qnil;
6423
6295
 
6424
6296
  arg4 = &temp4;
@@ -6461,13 +6333,13 @@ _wrap_memcached_stat_get_keys(int argc, VALUE *argv, VALUE self) {
6461
6333
  memcached_st *arg1 = (memcached_st *) 0 ;
6462
6334
  memcached_stat_st *arg2 = (memcached_stat_st *) 0 ;
6463
6335
  memcached_return *arg3 = (memcached_return *) 0 ;
6464
- char **result = 0 ;
6465
6336
  void *argp1 = 0 ;
6466
6337
  int res1 = 0 ;
6467
6338
  void *argp2 = 0 ;
6468
6339
  int res2 = 0 ;
6469
6340
  memcached_return temp3 ;
6470
6341
  int res3 = SWIG_TMPOBJ ;
6342
+ char **result = 0 ;
6471
6343
  VALUE vresult = Qnil;
6472
6344
 
6473
6345
  arg3 = &temp3;
@@ -6509,61 +6381,38 @@ fail:
6509
6381
 
6510
6382
 
6511
6383
  SWIGINTERN VALUE
6512
- _wrap_memcached_get_by_key(int argc, VALUE *argv, VALUE self) {
6384
+ _wrap_memcached_delete_by_key(int argc, VALUE *argv, VALUE self) {
6513
6385
  memcached_st *arg1 = (memcached_st *) 0 ;
6514
6386
  char *arg2 = (char *) 0 ;
6515
6387
  size_t arg3 ;
6516
6388
  char *arg4 = (char *) 0 ;
6517
6389
  size_t arg5 ;
6518
- size_t *arg6 = (size_t *) 0 ;
6519
- uint32_t *arg7 = (uint32_t *) 0 ;
6520
- memcached_return *arg8 = (memcached_return *) 0 ;
6521
- char *result = 0 ;
6390
+ time_t arg6 ;
6522
6391
  void *argp1 = 0 ;
6523
6392
  int res1 = 0 ;
6524
- size_t temp6 ;
6525
- int res6 = SWIG_TMPOBJ ;
6526
- uint32_t temp7 ;
6527
- int res7 = SWIG_TMPOBJ ;
6528
- memcached_return temp8 ;
6529
- int res8 = SWIG_TMPOBJ ;
6393
+ memcached_return result;
6530
6394
  VALUE vresult = Qnil;
6531
6395
 
6532
- arg6 = &temp6;
6533
- arg7 = &temp7;
6534
- arg8 = &temp8;
6535
- if ((argc < 2) || (argc > 2)) {
6536
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6396
+ if ((argc < 3) || (argc > 3)) {
6397
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
6537
6398
  }
6538
6399
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6539
6400
  if (!SWIG_IsOK(res1)) {
6540
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_get_by_key", 1, argv[0] ));
6401
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_delete_by_key", 1, argv[0] ));
6541
6402
  }
6542
6403
  arg1 = (memcached_st *)(argp1);
6543
6404
  {
6544
6405
  arg4 = arg2 = STR2CSTR(argv[1]);
6545
6406
  arg5 = arg3 = (size_t) RSTRING(argv[1])->len;
6546
6407
  }
6547
- result = (char *)memcached_get_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
6548
- vresult = SWIG_FromCharPtr((const char *)result);
6549
- if (SWIG_IsTmpObj(res6)) {
6550
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg6)));
6551
- } else {
6552
- int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6553
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_size_t, new_flags));
6554
- }
6555
- if (SWIG_IsTmpObj(res7)) {
6556
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg7)));
6557
- } else {
6558
- int new_flags = SWIG_IsNewObj(res7) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6559
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg7), SWIGTYPE_p_uint32_t, new_flags));
6560
- }
6561
- if (SWIG_IsTmpObj(res8)) {
6562
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg8)));
6563
- } else {
6564
- int new_flags = SWIG_IsNewObj(res8) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6565
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg8), SWIGTYPE_p_memcached_return, new_flags));
6408
+ {
6409
+ if (NIL_P(argv[2]))
6410
+ arg6 = (time_t)-1;
6411
+ else
6412
+ arg6 = NUM2LONG(rb_funcall(argv[2], rb_intern("tv_sec"), 0));
6566
6413
  }
6414
+ result = (memcached_return)memcached_delete_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6);
6415
+ vresult = SWIG_From_int((int)(result));
6567
6416
  return vresult;
6568
6417
  fail:
6569
6418
  return Qnil;
@@ -6571,81 +6420,61 @@ fail:
6571
6420
 
6572
6421
 
6573
6422
  SWIGINTERN VALUE
6574
- _wrap_memcached_mget_by_key(int argc, VALUE *argv, VALUE self) {
6423
+ _wrap_memcached_fetch_execute(int argc, VALUE *argv, VALUE self) {
6575
6424
  memcached_st *arg1 = (memcached_st *) 0 ;
6576
- char *arg2 = (char *) 0 ;
6577
- size_t arg3 ;
6578
- char **arg4 = (char **) 0 ;
6579
- size_t *arg5 = (size_t *) 0 ;
6580
- unsigned int arg6 ;
6581
- memcached_return result;
6425
+ memcached_execute_function *arg2 = (memcached_execute_function *) 0 ;
6426
+ void *arg3 = (void *) 0 ;
6427
+ unsigned int arg4 ;
6582
6428
  void *argp1 = 0 ;
6583
6429
  int res1 = 0 ;
6584
- int res2 ;
6585
- char *buf2 = 0 ;
6586
- int alloc2 = 0 ;
6587
- size_t val3 ;
6588
- int ecode3 = 0 ;
6589
- VALUE vresult = Qnil;
6590
-
6430
+ void *argp2 = 0 ;
6431
+ int res2 = 0 ;
6432
+ int res3 ;
6433
+ unsigned int val4 ;
6434
+ int ecode4 = 0 ;
6435
+ memcached_return result;
6436
+ VALUE vresult = Qnil;
6437
+
6591
6438
  if ((argc < 4) || (argc > 4)) {
6592
6439
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
6593
6440
  }
6594
6441
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6595
6442
  if (!SWIG_IsOK(res1)) {
6596
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_mget_by_key", 1, argv[0] ));
6443
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch_execute", 1, argv[0] ));
6597
6444
  }
6598
6445
  arg1 = (memcached_st *)(argp1);
6599
- res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6446
+ res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_execute_function, 0 | 0 );
6600
6447
  if (!SWIG_IsOK(res2)) {
6601
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","memcached_mget_by_key", 2, argv[1] ));
6448
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_execute_function *","memcached_fetch_execute", 2, argv[1] ));
6602
6449
  }
6603
- arg2 = (char *)(buf2);
6604
- ecode3 = SWIG_AsVal_size_t(argv[2], &val3);
6605
- if (!SWIG_IsOK(ecode3)) {
6606
- SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "size_t","memcached_mget_by_key", 3, argv[2] ));
6607
- }
6608
- arg3 = (size_t)(val3);
6609
- {
6610
- int i;
6611
- Check_Type(argv[3], T_ARRAY);
6612
- arg6 = (unsigned int) RARRAY_LEN(argv[3]);
6613
- arg5 = (size_t *) malloc((arg6+1)*sizeof(size_t));
6614
- arg4 = (char **) malloc((arg6+1)*sizeof(char *));
6615
- for(i = 0; i < arg6; i ++) {
6616
- arg5[i] = strlen(StringValuePtr(RARRAY_PTR(argv[3])[i]));
6617
- arg4[i] = StringValuePtr(RARRAY_PTR(argv[3])[i]);
6618
- }
6450
+ arg2 = (memcached_execute_function *)(argp2);
6451
+ res3 = SWIG_ConvertPtr(argv[2],SWIG_as_voidptrptr(&arg3), 0, 0);
6452
+ if (!SWIG_IsOK(res3)) {
6453
+ SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "void *","memcached_fetch_execute", 3, argv[2] ));
6619
6454
  }
6620
- result = (memcached_return)memcached_mget_by_key(arg1,arg2,arg3,arg4,arg5,arg6);
6455
+ ecode4 = SWIG_AsVal_unsigned_SS_int(argv[3], &val4);
6456
+ if (!SWIG_IsOK(ecode4)) {
6457
+ SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","memcached_fetch_execute", 4, argv[3] ));
6458
+ }
6459
+ arg4 = (unsigned int)(val4);
6460
+ result = (memcached_return)memcached_fetch_execute(arg1,arg2,arg3,arg4);
6621
6461
  vresult = SWIG_From_int((int)(result));
6622
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6623
- {
6624
- free(arg4);
6625
- free(arg5);
6626
- }
6627
6462
  return vresult;
6628
6463
  fail:
6629
- if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6630
- {
6631
- free(arg4);
6632
- free(arg5);
6633
- }
6634
6464
  return Qnil;
6635
6465
  }
6636
6466
 
6637
6467
 
6638
6468
  SWIGINTERN VALUE
6639
- _wrap_memcached_delete_by_key(int argc, VALUE *argv, VALUE self) {
6469
+ _wrap_memcached_callback_set(int argc, VALUE *argv, VALUE self) {
6640
6470
  memcached_st *arg1 = (memcached_st *) 0 ;
6641
- char *arg2 = (char *) 0 ;
6642
- size_t arg3 ;
6643
- char *arg4 = (char *) 0 ;
6644
- size_t arg5 ;
6645
- time_t arg6 ;
6646
- memcached_return result;
6471
+ memcached_callback arg2 ;
6472
+ void *arg3 = (void *) 0 ;
6647
6473
  void *argp1 = 0 ;
6648
6474
  int res1 = 0 ;
6475
+ int val2 ;
6476
+ int ecode2 = 0 ;
6477
+ memcached_return result;
6649
6478
  VALUE vresult = Qnil;
6650
6479
 
6651
6480
  if ((argc < 3) || (argc > 3)) {
@@ -6653,20 +6482,18 @@ _wrap_memcached_delete_by_key(int argc, VALUE *argv, VALUE self) {
6653
6482
  }
6654
6483
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6655
6484
  if (!SWIG_IsOK(res1)) {
6656
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_delete_by_key", 1, argv[0] ));
6485
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_callback_set", 1, argv[0] ));
6657
6486
  }
6658
6487
  arg1 = (memcached_st *)(argp1);
6488
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
6489
+ if (!SWIG_IsOK(ecode2)) {
6490
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "memcached_callback","memcached_callback_set", 2, argv[1] ));
6491
+ }
6492
+ arg2 = (memcached_callback)(val2);
6659
6493
  {
6660
- arg4 = arg2 = STR2CSTR(argv[1]);
6661
- arg5 = arg3 = (size_t) RSTRING(argv[1])->len;
6662
- }
6663
- {
6664
- if (NIL_P(argv[2]))
6665
- arg6 = (time_t)-1;
6666
- else
6667
- arg6 = NUM2LONG(rb_funcall(argv[2], rb_intern("tv_sec"), 0));
6494
+ arg3 = STR2CSTR(argv[2]);
6668
6495
  }
6669
- result = (memcached_return)memcached_delete_by_key(arg1,arg2,arg3,arg4,arg5,arg6);
6496
+ result = (memcached_return)memcached_callback_set(arg1,arg2,arg3);
6670
6497
  vresult = SWIG_From_int((int)(result));
6671
6498
  return vresult;
6672
6499
  fail:
@@ -6675,12 +6502,53 @@ fail:
6675
6502
 
6676
6503
 
6677
6504
  SWIGINTERN VALUE
6678
- _wrap_memcached_fetch_execute(int argc, VALUE *argv, VALUE self) {
6505
+ _wrap_memcached_callback_get(int argc, VALUE *argv, VALUE self) {
6679
6506
  memcached_st *arg1 = (memcached_st *) 0 ;
6680
- memcached_execute_function *arg2 = (memcached_execute_function *) 0 ;
6507
+ memcached_callback arg2 ;
6508
+ memcached_return *arg3 = (memcached_return *) 0 ;
6509
+ void *argp1 = 0 ;
6510
+ int res1 = 0 ;
6511
+ int val2 ;
6512
+ int ecode2 = 0 ;
6513
+ memcached_return temp3 ;
6514
+ int res3 = SWIG_TMPOBJ ;
6515
+ void *result = 0 ;
6516
+ VALUE vresult = Qnil;
6517
+
6518
+ arg3 = &temp3;
6519
+ if ((argc < 2) || (argc > 2)) {
6520
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6521
+ }
6522
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6523
+ if (!SWIG_IsOK(res1)) {
6524
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_callback_get", 1, argv[0] ));
6525
+ }
6526
+ arg1 = (memcached_st *)(argp1);
6527
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
6528
+ if (!SWIG_IsOK(ecode2)) {
6529
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "memcached_callback","memcached_callback_get", 2, argv[1] ));
6530
+ }
6531
+ arg2 = (memcached_callback)(val2);
6532
+ result = (void *)memcached_callback_get(arg1,arg2,arg3);
6533
+ vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 | 0 );
6534
+ if (SWIG_IsTmpObj(res3)) {
6535
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg3)));
6536
+ } else {
6537
+ int new_flags = SWIG_IsNewObj(res3) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6538
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg3), SWIGTYPE_p_memcached_return, new_flags));
6539
+ }
6540
+ return vresult;
6541
+ fail:
6542
+ return Qnil;
6543
+ }
6544
+
6545
+
6546
+ SWIGINTERN VALUE
6547
+ _wrap_memcached_server_cursor(int argc, VALUE *argv, VALUE self) {
6548
+ memcached_st *arg1 = (memcached_st *) 0 ;
6549
+ memcached_server_function *arg2 = (memcached_server_function *) 0 ;
6681
6550
  void *arg3 = (void *) 0 ;
6682
6551
  unsigned int arg4 ;
6683
- memcached_return result;
6684
6552
  void *argp1 = 0 ;
6685
6553
  int res1 = 0 ;
6686
6554
  void *argp2 = 0 ;
@@ -6688,6 +6556,7 @@ _wrap_memcached_fetch_execute(int argc, VALUE *argv, VALUE self) {
6688
6556
  int res3 ;
6689
6557
  unsigned int val4 ;
6690
6558
  int ecode4 = 0 ;
6559
+ memcached_return result;
6691
6560
  VALUE vresult = Qnil;
6692
6561
 
6693
6562
  if ((argc < 4) || (argc > 4)) {
@@ -6695,24 +6564,24 @@ _wrap_memcached_fetch_execute(int argc, VALUE *argv, VALUE self) {
6695
6564
  }
6696
6565
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6697
6566
  if (!SWIG_IsOK(res1)) {
6698
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch_execute", 1, argv[0] ));
6567
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_cursor", 1, argv[0] ));
6699
6568
  }
6700
6569
  arg1 = (memcached_st *)(argp1);
6701
- res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_execute_function, 0 | 0 );
6570
+ res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_server_function, 0 | 0 );
6702
6571
  if (!SWIG_IsOK(res2)) {
6703
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_execute_function *","memcached_fetch_execute", 2, argv[1] ));
6572
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_server_function *","memcached_server_cursor", 2, argv[1] ));
6704
6573
  }
6705
- arg2 = (memcached_execute_function *)(argp2);
6574
+ arg2 = (memcached_server_function *)(argp2);
6706
6575
  res3 = SWIG_ConvertPtr(argv[2],SWIG_as_voidptrptr(&arg3), 0, 0);
6707
6576
  if (!SWIG_IsOK(res3)) {
6708
- SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "void *","memcached_fetch_execute", 3, argv[2] ));
6577
+ SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "void *","memcached_server_cursor", 3, argv[2] ));
6709
6578
  }
6710
6579
  ecode4 = SWIG_AsVal_unsigned_SS_int(argv[3], &val4);
6711
6580
  if (!SWIG_IsOK(ecode4)) {
6712
- SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","memcached_fetch_execute", 4, argv[3] ));
6581
+ SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","memcached_server_cursor", 4, argv[3] ));
6713
6582
  }
6714
6583
  arg4 = (unsigned int)(val4);
6715
- result = (memcached_return)memcached_fetch_execute(arg1,arg2,arg3,arg4);
6584
+ result = (memcached_return)memcached_server_cursor(arg1,arg2,arg3,arg4);
6716
6585
  vresult = SWIG_From_int((int)(result));
6717
6586
  return vresult;
6718
6587
  fail:
@@ -6721,78 +6590,297 @@ fail:
6721
6590
 
6722
6591
 
6723
6592
  SWIGINTERN VALUE
6724
- _wrap_memcached_callback_set(int argc, VALUE *argv, VALUE self) {
6593
+ _wrap_memcached_get(int argc, VALUE *argv, VALUE self) {
6725
6594
  memcached_st *arg1 = (memcached_st *) 0 ;
6726
- memcached_callback arg2 ;
6727
- void *arg3 = (void *) 0 ;
6728
- memcached_return result;
6595
+ char *arg2 = (char *) 0 ;
6596
+ size_t arg3 ;
6597
+ size_t *arg4 = (size_t *) 0 ;
6598
+ uint32_t *arg5 = (uint32_t *) 0 ;
6599
+ memcached_return *arg6 = (memcached_return *) 0 ;
6729
6600
  void *argp1 = 0 ;
6730
6601
  int res1 = 0 ;
6731
- int val2 ;
6732
- int ecode2 = 0 ;
6733
- int res3 ;
6602
+ size_t temp4 ;
6603
+ int res4 = SWIG_TMPOBJ ;
6604
+ uint32_t temp5 ;
6605
+ int res5 = SWIG_TMPOBJ ;
6606
+ memcached_return temp6 ;
6607
+ int res6 = SWIG_TMPOBJ ;
6608
+ char *result = 0 ;
6734
6609
  VALUE vresult = Qnil;
6735
6610
 
6736
- if ((argc < 3) || (argc > 3)) {
6737
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
6611
+ arg4 = &temp4;
6612
+ arg5 = &temp5;
6613
+ arg6 = &temp6;
6614
+ if ((argc < 2) || (argc > 2)) {
6615
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6738
6616
  }
6739
6617
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6740
6618
  if (!SWIG_IsOK(res1)) {
6741
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_callback_set", 1, argv[0] ));
6619
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_get", 1, argv[0] ));
6742
6620
  }
6743
6621
  arg1 = (memcached_st *)(argp1);
6744
- ecode2 = SWIG_AsVal_int(argv[1], &val2);
6745
- if (!SWIG_IsOK(ecode2)) {
6746
- SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "memcached_callback","memcached_callback_set", 2, argv[1] ));
6747
- }
6748
- arg2 = (memcached_callback)(val2);
6749
- res3 = SWIG_ConvertPtr(argv[2],SWIG_as_voidptrptr(&arg3), 0, 0);
6750
- if (!SWIG_IsOK(res3)) {
6751
- SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "void *","memcached_callback_set", 3, argv[2] ));
6622
+ {
6623
+ arg2 = STR2CSTR(argv[1]);
6624
+ arg3 = (size_t) RSTRING(argv[1])->len;
6752
6625
  }
6753
- result = (memcached_return)memcached_callback_set(arg1,arg2,arg3);
6626
+ result = (char *)memcached_get(arg1,(char const *)arg2,arg3,arg4,arg5,arg6);
6627
+ vresult = SWIG_FromCharPtr((const char *)result);
6628
+ if (SWIG_IsTmpObj(res4)) {
6629
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg4)));
6630
+ } else {
6631
+ int new_flags = SWIG_IsNewObj(res4) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6632
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg4), SWIGTYPE_p_size_t, new_flags));
6633
+ }
6634
+ if (SWIG_IsTmpObj(res5)) {
6635
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg5)));
6636
+ } else {
6637
+ int new_flags = SWIG_IsNewObj(res5) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6638
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg5), SWIGTYPE_p_uint32_t, new_flags));
6639
+ }
6640
+ if (SWIG_IsTmpObj(res6)) {
6641
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg6)));
6642
+ } else {
6643
+ int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6644
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_memcached_return, new_flags));
6645
+ }
6646
+ return vresult;
6647
+ fail:
6648
+ return Qnil;
6649
+ }
6650
+
6651
+
6652
+ SWIGINTERN VALUE
6653
+ _wrap_memcached_mget(int argc, VALUE *argv, VALUE self) {
6654
+ memcached_st *arg1 = (memcached_st *) 0 ;
6655
+ char **arg2 = (char **) 0 ;
6656
+ size_t *arg3 = (size_t *) 0 ;
6657
+ unsigned int arg4 ;
6658
+ void *argp1 = 0 ;
6659
+ int res1 = 0 ;
6660
+ memcached_return result;
6661
+ VALUE vresult = Qnil;
6662
+
6663
+ if ((argc < 2) || (argc > 2)) {
6664
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6665
+ }
6666
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6667
+ if (!SWIG_IsOK(res1)) {
6668
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_mget", 1, argv[0] ));
6669
+ }
6670
+ arg1 = (memcached_st *)(argp1);
6671
+ {
6672
+ int i;
6673
+ Check_Type(argv[1], T_ARRAY);
6674
+ arg4 = (unsigned int) RARRAY_LEN(argv[1]);
6675
+ arg3 = (size_t *) malloc((arg4+1)*sizeof(size_t));
6676
+ arg2 = (char **) malloc((arg4+1)*sizeof(char *));
6677
+ for(i = 0; i < arg4; i ++) {
6678
+ arg3[i] = RSTRING(RARRAY_PTR(argv[1])[i])->len;
6679
+ arg2[i] = StringValuePtr(RARRAY_PTR(argv[1])[i]);
6680
+ }
6681
+ }
6682
+ result = (memcached_return)memcached_mget(arg1,arg2,arg3,arg4);
6754
6683
  vresult = SWIG_From_int((int)(result));
6684
+ {
6685
+ free(arg2);
6686
+ free(arg3);
6687
+ }
6755
6688
  return vresult;
6756
6689
  fail:
6690
+ {
6691
+ free(arg2);
6692
+ free(arg3);
6693
+ }
6757
6694
  return Qnil;
6758
6695
  }
6759
6696
 
6760
6697
 
6761
6698
  SWIGINTERN VALUE
6762
- _wrap_memcached_callback_get(int argc, VALUE *argv, VALUE self) {
6699
+ _wrap_memcached_get_by_key(int argc, VALUE *argv, VALUE self) {
6763
6700
  memcached_st *arg1 = (memcached_st *) 0 ;
6764
- memcached_callback arg2 ;
6765
- memcached_return *arg3 = (memcached_return *) 0 ;
6766
- void *result = 0 ;
6701
+ char *arg2 = (char *) 0 ;
6702
+ size_t arg3 ;
6703
+ char *arg4 = (char *) 0 ;
6704
+ size_t arg5 ;
6705
+ size_t *arg6 = (size_t *) 0 ;
6706
+ uint32_t *arg7 = (uint32_t *) 0 ;
6707
+ memcached_return *arg8 = (memcached_return *) 0 ;
6767
6708
  void *argp1 = 0 ;
6768
6709
  int res1 = 0 ;
6769
- int val2 ;
6770
- int ecode2 = 0 ;
6771
- memcached_return temp3 ;
6772
- int res3 = SWIG_TMPOBJ ;
6710
+ size_t temp6 ;
6711
+ int res6 = SWIG_TMPOBJ ;
6712
+ uint32_t temp7 ;
6713
+ int res7 = SWIG_TMPOBJ ;
6714
+ memcached_return temp8 ;
6715
+ int res8 = SWIG_TMPOBJ ;
6716
+ char *result = 0 ;
6773
6717
  VALUE vresult = Qnil;
6774
6718
 
6775
- arg3 = &temp3;
6719
+ arg6 = &temp6;
6720
+ arg7 = &temp7;
6721
+ arg8 = &temp8;
6776
6722
  if ((argc < 2) || (argc > 2)) {
6777
6723
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6778
6724
  }
6779
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6780
- if (!SWIG_IsOK(res1)) {
6781
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_callback_get", 1, argv[0] ));
6725
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6726
+ if (!SWIG_IsOK(res1)) {
6727
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_get_by_key", 1, argv[0] ));
6728
+ }
6729
+ arg1 = (memcached_st *)(argp1);
6730
+ {
6731
+ arg4 = arg2 = STR2CSTR(argv[1]);
6732
+ arg5 = arg3 = (size_t) RSTRING(argv[1])->len;
6733
+ }
6734
+ result = (char *)memcached_get_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7,arg8);
6735
+ vresult = SWIG_FromCharPtr((const char *)result);
6736
+ if (SWIG_IsTmpObj(res6)) {
6737
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg6)));
6738
+ } else {
6739
+ int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6740
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_size_t, new_flags));
6741
+ }
6742
+ if (SWIG_IsTmpObj(res7)) {
6743
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg7)));
6744
+ } else {
6745
+ int new_flags = SWIG_IsNewObj(res7) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6746
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg7), SWIGTYPE_p_uint32_t, new_flags));
6747
+ }
6748
+ if (SWIG_IsTmpObj(res8)) {
6749
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg8)));
6750
+ } else {
6751
+ int new_flags = SWIG_IsNewObj(res8) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6752
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg8), SWIGTYPE_p_memcached_return, new_flags));
6753
+ }
6754
+ return vresult;
6755
+ fail:
6756
+ return Qnil;
6757
+ }
6758
+
6759
+
6760
+ SWIGINTERN VALUE
6761
+ _wrap_memcached_mget_by_key(int argc, VALUE *argv, VALUE self) {
6762
+ memcached_st *arg1 = (memcached_st *) 0 ;
6763
+ char *arg2 = (char *) 0 ;
6764
+ size_t arg3 ;
6765
+ char **arg4 = (char **) 0 ;
6766
+ size_t *arg5 = (size_t *) 0 ;
6767
+ unsigned int arg6 ;
6768
+ void *argp1 = 0 ;
6769
+ int res1 = 0 ;
6770
+ int res2 ;
6771
+ char *buf2 = 0 ;
6772
+ int alloc2 = 0 ;
6773
+ size_t val3 ;
6774
+ int ecode3 = 0 ;
6775
+ memcached_return result;
6776
+ VALUE vresult = Qnil;
6777
+
6778
+ if ((argc < 4) || (argc > 4)) {
6779
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
6780
+ }
6781
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6782
+ if (!SWIG_IsOK(res1)) {
6783
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_mget_by_key", 1, argv[0] ));
6784
+ }
6785
+ arg1 = (memcached_st *)(argp1);
6786
+ res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2);
6787
+ if (!SWIG_IsOK(res2)) {
6788
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","memcached_mget_by_key", 2, argv[1] ));
6789
+ }
6790
+ arg2 = (char *)(buf2);
6791
+ ecode3 = SWIG_AsVal_size_t(argv[2], &val3);
6792
+ if (!SWIG_IsOK(ecode3)) {
6793
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "size_t","memcached_mget_by_key", 3, argv[2] ));
6794
+ }
6795
+ arg3 = (size_t)(val3);
6796
+ {
6797
+ int i;
6798
+ Check_Type(argv[3], T_ARRAY);
6799
+ arg6 = (unsigned int) RARRAY_LEN(argv[3]);
6800
+ arg5 = (size_t *) malloc((arg6+1)*sizeof(size_t));
6801
+ arg4 = (char **) malloc((arg6+1)*sizeof(char *));
6802
+ for(i = 0; i < arg6; i ++) {
6803
+ arg5[i] = RSTRING(RARRAY_PTR(argv[3])[i])->len;
6804
+ arg4[i] = StringValuePtr(RARRAY_PTR(argv[3])[i]);
6805
+ }
6806
+ }
6807
+ result = (memcached_return)memcached_mget_by_key(arg1,(char const *)arg2,arg3,arg4,arg5,arg6);
6808
+ vresult = SWIG_From_int((int)(result));
6809
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6810
+ {
6811
+ free(arg4);
6812
+ free(arg5);
6813
+ }
6814
+ return vresult;
6815
+ fail:
6816
+ if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
6817
+ {
6818
+ free(arg4);
6819
+ free(arg5);
6820
+ }
6821
+ return Qnil;
6822
+ }
6823
+
6824
+
6825
+ SWIGINTERN VALUE
6826
+ _wrap_memcached_fetch(int argc, VALUE *argv, VALUE self) {
6827
+ memcached_st *arg1 = (memcached_st *) 0 ;
6828
+ char *arg2 = (char *) 0 ;
6829
+ size_t *arg3 = (size_t *) 0 ;
6830
+ size_t *arg4 = (size_t *) 0 ;
6831
+ uint32_t *arg5 = (uint32_t *) 0 ;
6832
+ memcached_return *arg6 = (memcached_return *) 0 ;
6833
+ void *argp1 = 0 ;
6834
+ int res1 = 0 ;
6835
+ size_t temp4 ;
6836
+ int res4 = SWIG_TMPOBJ ;
6837
+ uint32_t temp5 ;
6838
+ int res5 = SWIG_TMPOBJ ;
6839
+ memcached_return temp6 ;
6840
+ int res6 = SWIG_TMPOBJ ;
6841
+ char *result = 0 ;
6842
+ VALUE vresult = Qnil;
6843
+
6844
+ {
6845
+ char string[256];
6846
+ size_t length = 0;
6847
+ arg2 = string;
6848
+ arg3 = &length;
6849
+ }
6850
+ arg4 = &temp4;
6851
+ arg5 = &temp5;
6852
+ arg6 = &temp6;
6853
+ if ((argc < 1) || (argc > 1)) {
6854
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6855
+ }
6856
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6857
+ if (!SWIG_IsOK(res1)) {
6858
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch", 1, argv[0] ));
6859
+ }
6860
+ arg1 = (memcached_st *)(argp1);
6861
+ result = (char *)memcached_fetch(arg1,arg2,arg3,arg4,arg5,arg6);
6862
+ vresult = SWIG_FromCharPtr((const char *)result);
6863
+ {
6864
+ // Pushes an empty string when *key_length == 0
6865
+ rb_ary_push(vresult, rb_str_new(arg2, *arg3));
6866
+ }
6867
+ if (SWIG_IsTmpObj(res4)) {
6868
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_size_t((*arg4)));
6869
+ } else {
6870
+ int new_flags = SWIG_IsNewObj(res4) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6871
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg4), SWIGTYPE_p_size_t, new_flags));
6872
+ }
6873
+ if (SWIG_IsTmpObj(res5)) {
6874
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg5)));
6875
+ } else {
6876
+ int new_flags = SWIG_IsNewObj(res5) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6877
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg5), SWIGTYPE_p_uint32_t, new_flags));
6782
6878
  }
6783
- arg1 = (memcached_st *)(argp1);
6784
- ecode2 = SWIG_AsVal_int(argv[1], &val2);
6785
- if (!SWIG_IsOK(ecode2)) {
6786
- SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "memcached_callback","memcached_callback_get", 2, argv[1] ));
6787
- }
6788
- arg2 = (memcached_callback)(val2);
6789
- result = (void *)memcached_callback_get(arg1,arg2,arg3);
6790
- vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 | 0 );
6791
- if (SWIG_IsTmpObj(res3)) {
6792
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg3)));
6879
+ if (SWIG_IsTmpObj(res6)) {
6880
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg6)));
6793
6881
  } else {
6794
- int new_flags = SWIG_IsNewObj(res3) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6795
- vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg3), SWIGTYPE_p_memcached_return, new_flags));
6882
+ int new_flags = SWIG_IsNewObj(res6) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6883
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg6), SWIGTYPE_p_memcached_return, new_flags));
6796
6884
  }
6797
6885
  return vresult;
6798
6886
  fail:
@@ -6801,45 +6889,41 @@ fail:
6801
6889
 
6802
6890
 
6803
6891
  SWIGINTERN VALUE
6804
- _wrap_memcached_server_cursor(int argc, VALUE *argv, VALUE self) {
6892
+ _wrap_memcached_fetch_result(int argc, VALUE *argv, VALUE self) {
6805
6893
  memcached_st *arg1 = (memcached_st *) 0 ;
6806
- memcached_server_function *arg2 = (memcached_server_function *) 0 ;
6807
- void *arg3 = (void *) 0 ;
6808
- unsigned int arg4 ;
6809
- memcached_return result;
6894
+ memcached_result_st *arg2 = (memcached_result_st *) 0 ;
6895
+ memcached_return *arg3 = (memcached_return *) 0 ;
6810
6896
  void *argp1 = 0 ;
6811
6897
  int res1 = 0 ;
6812
6898
  void *argp2 = 0 ;
6813
6899
  int res2 = 0 ;
6814
- int res3 ;
6815
- unsigned int val4 ;
6816
- int ecode4 = 0 ;
6900
+ memcached_return temp3 ;
6901
+ int res3 = SWIG_TMPOBJ ;
6902
+ memcached_result_st *result = 0 ;
6817
6903
  VALUE vresult = Qnil;
6818
6904
 
6819
- if ((argc < 4) || (argc > 4)) {
6820
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
6905
+ arg3 = &temp3;
6906
+ if ((argc < 2) || (argc > 2)) {
6907
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
6821
6908
  }
6822
6909
  res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
6823
6910
  if (!SWIG_IsOK(res1)) {
6824
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_server_cursor", 1, argv[0] ));
6911
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_fetch_result", 1, argv[0] ));
6825
6912
  }
6826
6913
  arg1 = (memcached_st *)(argp1);
6827
- res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_server_function, 0 | 0 );
6914
+ res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_memcached_result_st, 0 | 0 );
6828
6915
  if (!SWIG_IsOK(res2)) {
6829
- SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_server_function *","memcached_server_cursor", 2, argv[1] ));
6916
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "memcached_result_st *","memcached_fetch_result", 2, argv[1] ));
6830
6917
  }
6831
- arg2 = (memcached_server_function *)(argp2);
6832
- res3 = SWIG_ConvertPtr(argv[2],SWIG_as_voidptrptr(&arg3), 0, 0);
6833
- if (!SWIG_IsOK(res3)) {
6834
- SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "void *","memcached_server_cursor", 3, argv[2] ));
6918
+ arg2 = (memcached_result_st *)(argp2);
6919
+ result = (memcached_result_st *)memcached_fetch_result(arg1,arg2,arg3);
6920
+ vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_memcached_result_st, 0 | 0 );
6921
+ if (SWIG_IsTmpObj(res3)) {
6922
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_short((*arg3)));
6923
+ } else {
6924
+ int new_flags = SWIG_IsNewObj(res3) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
6925
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg3), SWIGTYPE_p_memcached_return, new_flags));
6835
6926
  }
6836
- ecode4 = SWIG_AsVal_unsigned_SS_int(argv[3], &val4);
6837
- if (!SWIG_IsOK(ecode4)) {
6838
- SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","memcached_server_cursor", 4, argv[3] ));
6839
- }
6840
- arg4 = (unsigned int)(val4);
6841
- result = (memcached_return)memcached_server_cursor(arg1,arg2,arg3,arg4);
6842
- vresult = SWIG_From_int((int)(result));
6843
6927
  return vresult;
6844
6928
  fail:
6845
6929
  return Qnil;
@@ -6855,11 +6939,11 @@ _wrap_memcached_set(int argc, VALUE *argv, VALUE self) {
6855
6939
  size_t arg5 ;
6856
6940
  time_t arg6 ;
6857
6941
  uint32_t arg7 ;
6858
- memcached_return result;
6859
6942
  void *argp1 = 0 ;
6860
6943
  int res1 = 0 ;
6861
6944
  unsigned long val7 ;
6862
6945
  int ecode7 = 0 ;
6946
+ memcached_return result;
6863
6947
  VALUE vresult = Qnil;
6864
6948
 
6865
6949
  if ((argc < 5) || (argc > 5)) {
@@ -6889,7 +6973,7 @@ _wrap_memcached_set(int argc, VALUE *argv, VALUE self) {
6889
6973
  SWIG_exception_fail(SWIG_ArgError(ecode7), Ruby_Format_TypeError( "", "uint32_t","memcached_set", 7, argv[4] ));
6890
6974
  }
6891
6975
  arg7 = (uint32_t)(val7);
6892
- result = (memcached_return)memcached_set(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
6976
+ result = (memcached_return)memcached_set(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7);
6893
6977
  vresult = SWIG_From_int((int)(result));
6894
6978
  return vresult;
6895
6979
  fail:
@@ -6906,11 +6990,11 @@ _wrap_memcached_add(int argc, VALUE *argv, VALUE self) {
6906
6990
  size_t arg5 ;
6907
6991
  time_t arg6 ;
6908
6992
  uint32_t arg7 ;
6909
- memcached_return result;
6910
6993
  void *argp1 = 0 ;
6911
6994
  int res1 = 0 ;
6912
6995
  unsigned long val7 ;
6913
6996
  int ecode7 = 0 ;
6997
+ memcached_return result;
6914
6998
  VALUE vresult = Qnil;
6915
6999
 
6916
7000
  if ((argc < 5) || (argc > 5)) {
@@ -6940,7 +7024,7 @@ _wrap_memcached_add(int argc, VALUE *argv, VALUE self) {
6940
7024
  SWIG_exception_fail(SWIG_ArgError(ecode7), Ruby_Format_TypeError( "", "uint32_t","memcached_add", 7, argv[4] ));
6941
7025
  }
6942
7026
  arg7 = (uint32_t)(val7);
6943
- result = (memcached_return)memcached_add(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
7027
+ result = (memcached_return)memcached_add(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7);
6944
7028
  vresult = SWIG_From_int((int)(result));
6945
7029
  return vresult;
6946
7030
  fail:
@@ -6957,11 +7041,11 @@ _wrap_memcached_replace(int argc, VALUE *argv, VALUE self) {
6957
7041
  size_t arg5 ;
6958
7042
  time_t arg6 ;
6959
7043
  uint32_t arg7 ;
6960
- memcached_return result;
6961
7044
  void *argp1 = 0 ;
6962
7045
  int res1 = 0 ;
6963
7046
  unsigned long val7 ;
6964
7047
  int ecode7 = 0 ;
7048
+ memcached_return result;
6965
7049
  VALUE vresult = Qnil;
6966
7050
 
6967
7051
  if ((argc < 5) || (argc > 5)) {
@@ -6991,7 +7075,7 @@ _wrap_memcached_replace(int argc, VALUE *argv, VALUE self) {
6991
7075
  SWIG_exception_fail(SWIG_ArgError(ecode7), Ruby_Format_TypeError( "", "uint32_t","memcached_replace", 7, argv[4] ));
6992
7076
  }
6993
7077
  arg7 = (uint32_t)(val7);
6994
- result = (memcached_return)memcached_replace(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
7078
+ result = (memcached_return)memcached_replace(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7);
6995
7079
  vresult = SWIG_From_int((int)(result));
6996
7080
  return vresult;
6997
7081
  fail:
@@ -7008,11 +7092,11 @@ _wrap_memcached_append(int argc, VALUE *argv, VALUE self) {
7008
7092
  size_t arg5 ;
7009
7093
  time_t arg6 ;
7010
7094
  uint32_t arg7 ;
7011
- memcached_return result;
7012
7095
  void *argp1 = 0 ;
7013
7096
  int res1 = 0 ;
7014
7097
  unsigned long val7 ;
7015
7098
  int ecode7 = 0 ;
7099
+ memcached_return result;
7016
7100
  VALUE vresult = Qnil;
7017
7101
 
7018
7102
  if ((argc < 5) || (argc > 5)) {
@@ -7042,7 +7126,7 @@ _wrap_memcached_append(int argc, VALUE *argv, VALUE self) {
7042
7126
  SWIG_exception_fail(SWIG_ArgError(ecode7), Ruby_Format_TypeError( "", "uint32_t","memcached_append", 7, argv[4] ));
7043
7127
  }
7044
7128
  arg7 = (uint32_t)(val7);
7045
- result = (memcached_return)memcached_append(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
7129
+ result = (memcached_return)memcached_append(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7);
7046
7130
  vresult = SWIG_From_int((int)(result));
7047
7131
  return vresult;
7048
7132
  fail:
@@ -7059,11 +7143,11 @@ _wrap_memcached_prepend(int argc, VALUE *argv, VALUE self) {
7059
7143
  size_t arg5 ;
7060
7144
  time_t arg6 ;
7061
7145
  uint32_t arg7 ;
7062
- memcached_return result;
7063
7146
  void *argp1 = 0 ;
7064
7147
  int res1 = 0 ;
7065
7148
  unsigned long val7 ;
7066
7149
  int ecode7 = 0 ;
7150
+ memcached_return result;
7067
7151
  VALUE vresult = Qnil;
7068
7152
 
7069
7153
  if ((argc < 5) || (argc > 5)) {
@@ -7093,7 +7177,7 @@ _wrap_memcached_prepend(int argc, VALUE *argv, VALUE self) {
7093
7177
  SWIG_exception_fail(SWIG_ArgError(ecode7), Ruby_Format_TypeError( "", "uint32_t","memcached_prepend", 7, argv[4] ));
7094
7178
  }
7095
7179
  arg7 = (uint32_t)(val7);
7096
- result = (memcached_return)memcached_prepend(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
7180
+ result = (memcached_return)memcached_prepend(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7);
7097
7181
  vresult = SWIG_From_int((int)(result));
7098
7182
  return vresult;
7099
7183
  fail:
@@ -7111,13 +7195,13 @@ _wrap_memcached_cas(int argc, VALUE *argv, VALUE self) {
7111
7195
  time_t arg6 ;
7112
7196
  uint32_t arg7 ;
7113
7197
  uint64_t arg8 ;
7114
- memcached_return result;
7115
7198
  void *argp1 = 0 ;
7116
7199
  int res1 = 0 ;
7117
7200
  unsigned long val7 ;
7118
7201
  int ecode7 = 0 ;
7119
7202
  unsigned long long val8 ;
7120
7203
  int ecode8 = 0 ;
7204
+ memcached_return result;
7121
7205
  VALUE vresult = Qnil;
7122
7206
 
7123
7207
  if ((argc < 6) || (argc > 6)) {
@@ -7152,7 +7236,7 @@ _wrap_memcached_cas(int argc, VALUE *argv, VALUE self) {
7152
7236
  SWIG_exception_fail(SWIG_ArgError(ecode8), Ruby_Format_TypeError( "", "uint64_t","memcached_cas", 8, argv[5] ));
7153
7237
  }
7154
7238
  arg8 = (uint64_t)(val8);
7155
- result = (memcached_return)memcached_cas(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
7239
+ result = (memcached_return)memcached_cas(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,arg6,arg7,arg8);
7156
7240
  vresult = SWIG_From_int((int)(result));
7157
7241
  return vresult;
7158
7242
  fail:
@@ -7171,11 +7255,11 @@ _wrap_memcached_set_by_key(int argc, VALUE *argv, VALUE self) {
7171
7255
  size_t arg7 ;
7172
7256
  time_t arg8 ;
7173
7257
  uint32_t arg9 ;
7174
- memcached_return result;
7175
7258
  void *argp1 = 0 ;
7176
7259
  int res1 = 0 ;
7177
7260
  unsigned long val9 ;
7178
7261
  int ecode9 = 0 ;
7262
+ memcached_return result;
7179
7263
  VALUE vresult = Qnil;
7180
7264
 
7181
7265
  if ((argc < 5) || (argc > 5)) {
@@ -7205,7 +7289,7 @@ _wrap_memcached_set_by_key(int argc, VALUE *argv, VALUE self) {
7205
7289
  SWIG_exception_fail(SWIG_ArgError(ecode9), Ruby_Format_TypeError( "", "uint32_t","memcached_set_by_key", 9, argv[4] ));
7206
7290
  }
7207
7291
  arg9 = (uint32_t)(val9);
7208
- result = (memcached_return)memcached_set_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
7292
+ result = (memcached_return)memcached_set_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9);
7209
7293
  vresult = SWIG_From_int((int)(result));
7210
7294
  return vresult;
7211
7295
  fail:
@@ -7224,11 +7308,11 @@ _wrap_memcached_add_by_key(int argc, VALUE *argv, VALUE self) {
7224
7308
  size_t arg7 ;
7225
7309
  time_t arg8 ;
7226
7310
  uint32_t arg9 ;
7227
- memcached_return result;
7228
7311
  void *argp1 = 0 ;
7229
7312
  int res1 = 0 ;
7230
7313
  unsigned long val9 ;
7231
7314
  int ecode9 = 0 ;
7315
+ memcached_return result;
7232
7316
  VALUE vresult = Qnil;
7233
7317
 
7234
7318
  if ((argc < 5) || (argc > 5)) {
@@ -7258,7 +7342,7 @@ _wrap_memcached_add_by_key(int argc, VALUE *argv, VALUE self) {
7258
7342
  SWIG_exception_fail(SWIG_ArgError(ecode9), Ruby_Format_TypeError( "", "uint32_t","memcached_add_by_key", 9, argv[4] ));
7259
7343
  }
7260
7344
  arg9 = (uint32_t)(val9);
7261
- result = (memcached_return)memcached_add_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
7345
+ result = (memcached_return)memcached_add_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9);
7262
7346
  vresult = SWIG_From_int((int)(result));
7263
7347
  return vresult;
7264
7348
  fail:
@@ -7277,11 +7361,11 @@ _wrap_memcached_replace_by_key(int argc, VALUE *argv, VALUE self) {
7277
7361
  size_t arg7 ;
7278
7362
  time_t arg8 ;
7279
7363
  uint32_t arg9 ;
7280
- memcached_return result;
7281
7364
  void *argp1 = 0 ;
7282
7365
  int res1 = 0 ;
7283
7366
  unsigned long val9 ;
7284
7367
  int ecode9 = 0 ;
7368
+ memcached_return result;
7285
7369
  VALUE vresult = Qnil;
7286
7370
 
7287
7371
  if ((argc < 5) || (argc > 5)) {
@@ -7311,7 +7395,7 @@ _wrap_memcached_replace_by_key(int argc, VALUE *argv, VALUE self) {
7311
7395
  SWIG_exception_fail(SWIG_ArgError(ecode9), Ruby_Format_TypeError( "", "uint32_t","memcached_replace_by_key", 9, argv[4] ));
7312
7396
  }
7313
7397
  arg9 = (uint32_t)(val9);
7314
- result = (memcached_return)memcached_replace_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
7398
+ result = (memcached_return)memcached_replace_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9);
7315
7399
  vresult = SWIG_From_int((int)(result));
7316
7400
  return vresult;
7317
7401
  fail:
@@ -7330,11 +7414,11 @@ _wrap_memcached_prepend_by_key(int argc, VALUE *argv, VALUE self) {
7330
7414
  size_t arg7 ;
7331
7415
  time_t arg8 ;
7332
7416
  uint32_t arg9 ;
7333
- memcached_return result;
7334
7417
  void *argp1 = 0 ;
7335
7418
  int res1 = 0 ;
7336
7419
  unsigned long val9 ;
7337
7420
  int ecode9 = 0 ;
7421
+ memcached_return result;
7338
7422
  VALUE vresult = Qnil;
7339
7423
 
7340
7424
  if ((argc < 5) || (argc > 5)) {
@@ -7364,7 +7448,7 @@ _wrap_memcached_prepend_by_key(int argc, VALUE *argv, VALUE self) {
7364
7448
  SWIG_exception_fail(SWIG_ArgError(ecode9), Ruby_Format_TypeError( "", "uint32_t","memcached_prepend_by_key", 9, argv[4] ));
7365
7449
  }
7366
7450
  arg9 = (uint32_t)(val9);
7367
- result = (memcached_return)memcached_prepend_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
7451
+ result = (memcached_return)memcached_prepend_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9);
7368
7452
  vresult = SWIG_From_int((int)(result));
7369
7453
  return vresult;
7370
7454
  fail:
@@ -7383,11 +7467,11 @@ _wrap_memcached_append_by_key(int argc, VALUE *argv, VALUE self) {
7383
7467
  size_t arg7 ;
7384
7468
  time_t arg8 ;
7385
7469
  uint32_t arg9 ;
7386
- memcached_return result;
7387
7470
  void *argp1 = 0 ;
7388
7471
  int res1 = 0 ;
7389
7472
  unsigned long val9 ;
7390
7473
  int ecode9 = 0 ;
7474
+ memcached_return result;
7391
7475
  VALUE vresult = Qnil;
7392
7476
 
7393
7477
  if ((argc < 5) || (argc > 5)) {
@@ -7417,7 +7501,7 @@ _wrap_memcached_append_by_key(int argc, VALUE *argv, VALUE self) {
7417
7501
  SWIG_exception_fail(SWIG_ArgError(ecode9), Ruby_Format_TypeError( "", "uint32_t","memcached_append_by_key", 9, argv[4] ));
7418
7502
  }
7419
7503
  arg9 = (uint32_t)(val9);
7420
- result = (memcached_return)memcached_append_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
7504
+ result = (memcached_return)memcached_append_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9);
7421
7505
  vresult = SWIG_From_int((int)(result));
7422
7506
  return vresult;
7423
7507
  fail:
@@ -7437,13 +7521,13 @@ _wrap_memcached_cas_by_key(int argc, VALUE *argv, VALUE self) {
7437
7521
  time_t arg8 ;
7438
7522
  uint32_t arg9 ;
7439
7523
  uint64_t arg10 ;
7440
- memcached_return result;
7441
7524
  void *argp1 = 0 ;
7442
7525
  int res1 = 0 ;
7443
7526
  unsigned long val9 ;
7444
7527
  int ecode9 = 0 ;
7445
7528
  unsigned long long val10 ;
7446
7529
  int ecode10 = 0 ;
7530
+ memcached_return result;
7447
7531
  VALUE vresult = Qnil;
7448
7532
 
7449
7533
  if ((argc < 6) || (argc > 6)) {
@@ -7478,7 +7562,7 @@ _wrap_memcached_cas_by_key(int argc, VALUE *argv, VALUE self) {
7478
7562
  SWIG_exception_fail(SWIG_ArgError(ecode10), Ruby_Format_TypeError( "", "uint64_t","memcached_cas_by_key", 10, argv[5] ));
7479
7563
  }
7480
7564
  arg10 = (uint64_t)(val10);
7481
- result = (memcached_return)memcached_cas_by_key(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10);
7565
+ result = (memcached_return)memcached_cas_by_key(arg1,(char const *)arg2,arg3,(char const *)arg4,arg5,(char const *)arg6,arg7,arg8,arg9,arg10);
7482
7566
  vresult = SWIG_From_int((int)(result));
7483
7567
  return vresult;
7484
7568
  fail:
@@ -7511,7 +7595,6 @@ _wrap_MemcachedResultSt_is_allocated_set(int argc, VALUE *argv, VALUE self) {
7511
7595
  }
7512
7596
  arg2 = (memcached_allocated)(val2);
7513
7597
  if (arg1) (arg1)->is_allocated = arg2;
7514
-
7515
7598
  return Qnil;
7516
7599
  fail:
7517
7600
  return Qnil;
@@ -7521,9 +7604,9 @@ fail:
7521
7604
  SWIGINTERN VALUE
7522
7605
  _wrap_MemcachedResultSt_is_allocated_get(int argc, VALUE *argv, VALUE self) {
7523
7606
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7524
- memcached_allocated result;
7525
7607
  void *argp1 = 0 ;
7526
7608
  int res1 = 0 ;
7609
+ memcached_allocated result;
7527
7610
  VALUE vresult = Qnil;
7528
7611
 
7529
7612
  if ((argc < 0) || (argc > 0)) {
@@ -7565,7 +7648,6 @@ _wrap_MemcachedResultSt_root_set(int argc, VALUE *argv, VALUE self) {
7565
7648
  }
7566
7649
  arg2 = (memcached_st *)(argp2);
7567
7650
  if (arg1) (arg1)->root = arg2;
7568
-
7569
7651
  return Qnil;
7570
7652
  fail:
7571
7653
  return Qnil;
@@ -7575,9 +7657,9 @@ fail:
7575
7657
  SWIGINTERN VALUE
7576
7658
  _wrap_MemcachedResultSt_root_get(int argc, VALUE *argv, VALUE self) {
7577
7659
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7578
- memcached_st *result = 0 ;
7579
7660
  void *argp1 = 0 ;
7580
7661
  int res1 = 0 ;
7662
+ memcached_st *result = 0 ;
7581
7663
  VALUE vresult = Qnil;
7582
7664
 
7583
7665
  if ((argc < 0) || (argc > 0)) {
@@ -7629,9 +7711,9 @@ fail:
7629
7711
  SWIGINTERN VALUE
7630
7712
  _wrap_MemcachedResultSt_key_get(int argc, VALUE *argv, VALUE self) {
7631
7713
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7632
- char *result = 0 ;
7633
7714
  void *argp1 = 0 ;
7634
7715
  int res1 = 0 ;
7716
+ char *result = 0 ;
7635
7717
  VALUE vresult = Qnil;
7636
7718
 
7637
7719
  if ((argc < 0) || (argc > 0)) {
@@ -7679,7 +7761,6 @@ _wrap_MemcachedResultSt_key_length_set(int argc, VALUE *argv, VALUE self) {
7679
7761
  }
7680
7762
  arg2 = (size_t)(val2);
7681
7763
  if (arg1) (arg1)->key_length = arg2;
7682
-
7683
7764
  return Qnil;
7684
7765
  fail:
7685
7766
  return Qnil;
@@ -7689,9 +7770,9 @@ fail:
7689
7770
  SWIGINTERN VALUE
7690
7771
  _wrap_MemcachedResultSt_key_length_get(int argc, VALUE *argv, VALUE self) {
7691
7772
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7692
- size_t result;
7693
7773
  void *argp1 = 0 ;
7694
7774
  int res1 = 0 ;
7775
+ size_t result;
7695
7776
  VALUE vresult = Qnil;
7696
7777
 
7697
7778
  if ((argc < 0) || (argc > 0)) {
@@ -7739,7 +7820,6 @@ _wrap_MemcachedResultSt_value_set(int argc, VALUE *argv, VALUE self) {
7739
7820
  }
7740
7821
  }
7741
7822
  if (arg1) (arg1)->value = arg2;
7742
-
7743
7823
  return Qnil;
7744
7824
  fail:
7745
7825
  return Qnil;
@@ -7749,9 +7829,9 @@ fail:
7749
7829
  SWIGINTERN VALUE
7750
7830
  _wrap_MemcachedResultSt_value_get(int argc, VALUE *argv, VALUE self) {
7751
7831
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7752
- memcached_string_st result;
7753
7832
  void *argp1 = 0 ;
7754
7833
  int res1 = 0 ;
7834
+ memcached_string_st result;
7755
7835
  VALUE vresult = Qnil;
7756
7836
 
7757
7837
  if ((argc < 0) || (argc > 0)) {
@@ -7793,7 +7873,6 @@ _wrap_MemcachedResultSt_flags_set(int argc, VALUE *argv, VALUE self) {
7793
7873
  }
7794
7874
  arg2 = (uint32_t)(val2);
7795
7875
  if (arg1) (arg1)->flags = arg2;
7796
-
7797
7876
  return Qnil;
7798
7877
  fail:
7799
7878
  return Qnil;
@@ -7803,9 +7882,9 @@ fail:
7803
7882
  SWIGINTERN VALUE
7804
7883
  _wrap_MemcachedResultSt_flags_get(int argc, VALUE *argv, VALUE self) {
7805
7884
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7806
- uint32_t result;
7807
7885
  void *argp1 = 0 ;
7808
7886
  int res1 = 0 ;
7887
+ uint32_t result;
7809
7888
  VALUE vresult = Qnil;
7810
7889
 
7811
7890
  if ((argc < 0) || (argc > 0)) {
@@ -7847,7 +7926,6 @@ _wrap_MemcachedResultSt_cas_set(int argc, VALUE *argv, VALUE self) {
7847
7926
  }
7848
7927
  arg2 = (uint64_t)(val2);
7849
7928
  if (arg1) (arg1)->cas = arg2;
7850
-
7851
7929
  return Qnil;
7852
7930
  fail:
7853
7931
  return Qnil;
@@ -7857,9 +7935,9 @@ fail:
7857
7935
  SWIGINTERN VALUE
7858
7936
  _wrap_MemcachedResultSt_cas_get(int argc, VALUE *argv, VALUE self) {
7859
7937
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7860
- uint64_t result;
7861
7938
  void *argp1 = 0 ;
7862
7939
  int res1 = 0 ;
7940
+ uint64_t result;
7863
7941
  VALUE vresult = Qnil;
7864
7942
 
7865
7943
  if ((argc < 0) || (argc > 0)) {
@@ -7900,7 +7978,6 @@ _wrap_MemcachedResultSt_expiration_set(int argc, VALUE *argv, VALUE self) {
7900
7978
  arg2 = NUM2LONG(rb_funcall(argv[0], rb_intern("tv_sec"), 0));
7901
7979
  }
7902
7980
  if (arg1) (arg1)->expiration = arg2;
7903
-
7904
7981
  return Qnil;
7905
7982
  fail:
7906
7983
  return Qnil;
@@ -7910,9 +7987,9 @@ fail:
7910
7987
  SWIGINTERN VALUE
7911
7988
  _wrap_MemcachedResultSt_expiration_get(int argc, VALUE *argv, VALUE self) {
7912
7989
  struct memcached_result_st *arg1 = (struct memcached_result_st *) 0 ;
7913
- time_t result;
7914
7990
  void *argp1 = 0 ;
7915
7991
  int res1 = 0 ;
7992
+ time_t result;
7916
7993
  VALUE vresult = Qnil;
7917
7994
 
7918
7995
  if ((argc < 0) || (argc > 0)) {
@@ -7957,8 +8034,8 @@ _wrap_new_MemcachedResultSt(int argc, VALUE *argv, VALUE self) {
7957
8034
  if ((argc < 0) || (argc > 0)) {
7958
8035
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7959
8036
  }
7960
- result = (struct memcached_result_st *)(struct memcached_result_st *) calloc(1, sizeof(struct memcached_result_st));DATA_PTR(self) = result;
7961
-
8037
+ result = (struct memcached_result_st *)calloc(1, sizeof(struct memcached_result_st));
8038
+ DATA_PTR(self) = result;
7962
8039
  return self;
7963
8040
  fail:
7964
8041
  return Qnil;
@@ -8016,11 +8093,11 @@ SWIGINTERN VALUE
8016
8093
  _wrap_memcached_result_create(int argc, VALUE *argv, VALUE self) {
8017
8094
  memcached_st *arg1 = (memcached_st *) 0 ;
8018
8095
  memcached_result_st *arg2 = (memcached_result_st *) 0 ;
8019
- memcached_result_st *result = 0 ;
8020
8096
  void *argp1 = 0 ;
8021
8097
  int res1 = 0 ;
8022
8098
  void *argp2 = 0 ;
8023
8099
  int res2 = 0 ;
8100
+ memcached_result_st *result = 0 ;
8024
8101
  VALUE vresult = Qnil;
8025
8102
 
8026
8103
  if ((argc < 2) || (argc > 2)) {
@@ -8047,9 +8124,9 @@ fail:
8047
8124
  SWIGINTERN VALUE
8048
8125
  _wrap_memcached_result_value(int argc, VALUE *argv, VALUE self) {
8049
8126
  memcached_result_st *arg1 = (memcached_result_st *) 0 ;
8050
- char *result = 0 ;
8051
8127
  void *argp1 = 0 ;
8052
8128
  int res1 = 0 ;
8129
+ char *result = 0 ;
8053
8130
  VALUE vresult = Qnil;
8054
8131
 
8055
8132
  if ((argc < 1) || (argc > 1)) {
@@ -8071,9 +8148,9 @@ fail:
8071
8148
  SWIGINTERN VALUE
8072
8149
  _wrap_memcached_result_length(int argc, VALUE *argv, VALUE self) {
8073
8150
  memcached_result_st *arg1 = (memcached_result_st *) 0 ;
8074
- size_t result;
8075
8151
  void *argp1 = 0 ;
8076
8152
  int res1 = 0 ;
8153
+ size_t result;
8077
8154
  VALUE vresult = Qnil;
8078
8155
 
8079
8156
  if ((argc < 1) || (argc > 1)) {
@@ -8097,7 +8174,6 @@ _wrap_memcached_result_set_value(int argc, VALUE *argv, VALUE self) {
8097
8174
  memcached_result_st *arg1 = (memcached_result_st *) 0 ;
8098
8175
  char *arg2 = (char *) 0 ;
8099
8176
  size_t arg3 ;
8100
- memcached_return result;
8101
8177
  void *argp1 = 0 ;
8102
8178
  int res1 = 0 ;
8103
8179
  int res2 ;
@@ -8105,6 +8181,7 @@ _wrap_memcached_result_set_value(int argc, VALUE *argv, VALUE self) {
8105
8181
  int alloc2 = 0 ;
8106
8182
  size_t val3 ;
8107
8183
  int ecode3 = 0 ;
8184
+ memcached_return result;
8108
8185
  VALUE vresult = Qnil;
8109
8186
 
8110
8187
  if ((argc < 3) || (argc > 3)) {
@@ -8170,9 +8247,9 @@ fail:
8170
8247
  SWIGINTERN VALUE
8171
8248
  _wrap_MemcachedServerSt_hostname_get(int argc, VALUE *argv, VALUE self) {
8172
8249
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8173
- char *result = 0 ;
8174
8250
  void *argp1 = 0 ;
8175
8251
  int res1 = 0 ;
8252
+ char *result = 0 ;
8176
8253
  VALUE vresult = Qnil;
8177
8254
 
8178
8255
  if ((argc < 0) || (argc > 0)) {
@@ -8220,7 +8297,6 @@ _wrap_MemcachedServerSt_port_set(int argc, VALUE *argv, VALUE self) {
8220
8297
  }
8221
8298
  arg2 = (unsigned int)(val2);
8222
8299
  if (arg1) (arg1)->port = arg2;
8223
-
8224
8300
  return Qnil;
8225
8301
  fail:
8226
8302
  return Qnil;
@@ -8230,9 +8306,9 @@ fail:
8230
8306
  SWIGINTERN VALUE
8231
8307
  _wrap_MemcachedServerSt_port_get(int argc, VALUE *argv, VALUE self) {
8232
8308
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8233
- unsigned int result;
8234
8309
  void *argp1 = 0 ;
8235
8310
  int res1 = 0 ;
8311
+ unsigned int result;
8236
8312
  VALUE vresult = Qnil;
8237
8313
 
8238
8314
  if ((argc < 0) || (argc > 0)) {
@@ -8274,7 +8350,6 @@ _wrap_MemcachedServerSt_fd_set(int argc, VALUE *argv, VALUE self) {
8274
8350
  }
8275
8351
  arg2 = (int)(val2);
8276
8352
  if (arg1) (arg1)->fd = arg2;
8277
-
8278
8353
  return Qnil;
8279
8354
  fail:
8280
8355
  return Qnil;
@@ -8284,9 +8359,9 @@ fail:
8284
8359
  SWIGINTERN VALUE
8285
8360
  _wrap_MemcachedServerSt_fd_get(int argc, VALUE *argv, VALUE self) {
8286
8361
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8287
- int result;
8288
8362
  void *argp1 = 0 ;
8289
8363
  int res1 = 0 ;
8364
+ int result;
8290
8365
  VALUE vresult = Qnil;
8291
8366
 
8292
8367
  if ((argc < 0) || (argc > 0)) {
@@ -8328,7 +8403,6 @@ _wrap_MemcachedServerSt_cached_errno_set(int argc, VALUE *argv, VALUE self) {
8328
8403
  }
8329
8404
  arg2 = (int)(val2);
8330
8405
  if (arg1) (arg1)->cached_errno = arg2;
8331
-
8332
8406
  return Qnil;
8333
8407
  fail:
8334
8408
  return Qnil;
@@ -8338,9 +8412,9 @@ fail:
8338
8412
  SWIGINTERN VALUE
8339
8413
  _wrap_MemcachedServerSt_cached_errno_get(int argc, VALUE *argv, VALUE self) {
8340
8414
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8341
- int result;
8342
8415
  void *argp1 = 0 ;
8343
8416
  int res1 = 0 ;
8417
+ int result;
8344
8418
  VALUE vresult = Qnil;
8345
8419
 
8346
8420
  if ((argc < 0) || (argc > 0)) {
@@ -8382,7 +8456,6 @@ _wrap_MemcachedServerSt_cursor_active_set(int argc, VALUE *argv, VALUE self) {
8382
8456
  }
8383
8457
  arg2 = (unsigned int)(val2);
8384
8458
  if (arg1) (arg1)->cursor_active = arg2;
8385
-
8386
8459
  return Qnil;
8387
8460
  fail:
8388
8461
  return Qnil;
@@ -8392,9 +8465,9 @@ fail:
8392
8465
  SWIGINTERN VALUE
8393
8466
  _wrap_MemcachedServerSt_cursor_active_get(int argc, VALUE *argv, VALUE self) {
8394
8467
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8395
- unsigned int result;
8396
8468
  void *argp1 = 0 ;
8397
8469
  int res1 = 0 ;
8470
+ unsigned int result;
8398
8471
  VALUE vresult = Qnil;
8399
8472
 
8400
8473
  if ((argc < 0) || (argc > 0)) {
@@ -8446,9 +8519,9 @@ fail:
8446
8519
  SWIGINTERN VALUE
8447
8520
  _wrap_MemcachedServerSt_write_buffer_get(int argc, VALUE *argv, VALUE self) {
8448
8521
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8449
- char *result = 0 ;
8450
8522
  void *argp1 = 0 ;
8451
8523
  int res1 = 0 ;
8524
+ char *result = 0 ;
8452
8525
  VALUE vresult = Qnil;
8453
8526
 
8454
8527
  if ((argc < 0) || (argc > 0)) {
@@ -8496,7 +8569,6 @@ _wrap_MemcachedServerSt_write_buffer_offset_set(int argc, VALUE *argv, VALUE sel
8496
8569
  }
8497
8570
  arg2 = (size_t)(val2);
8498
8571
  if (arg1) (arg1)->write_buffer_offset = arg2;
8499
-
8500
8572
  return Qnil;
8501
8573
  fail:
8502
8574
  return Qnil;
@@ -8506,9 +8578,9 @@ fail:
8506
8578
  SWIGINTERN VALUE
8507
8579
  _wrap_MemcachedServerSt_write_buffer_offset_get(int argc, VALUE *argv, VALUE self) {
8508
8580
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8509
- size_t result;
8510
8581
  void *argp1 = 0 ;
8511
8582
  int res1 = 0 ;
8583
+ size_t result;
8512
8584
  VALUE vresult = Qnil;
8513
8585
 
8514
8586
  if ((argc < 0) || (argc > 0)) {
@@ -8560,9 +8632,9 @@ fail:
8560
8632
  SWIGINTERN VALUE
8561
8633
  _wrap_MemcachedServerSt_read_buffer_get(int argc, VALUE *argv, VALUE self) {
8562
8634
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8563
- char *result = 0 ;
8564
8635
  void *argp1 = 0 ;
8565
8636
  int res1 = 0 ;
8637
+ char *result = 0 ;
8566
8638
  VALUE vresult = Qnil;
8567
8639
 
8568
8640
  if ((argc < 0) || (argc > 0)) {
@@ -8610,7 +8682,6 @@ _wrap_MemcachedServerSt_read_data_length_set(int argc, VALUE *argv, VALUE self)
8610
8682
  }
8611
8683
  arg2 = (size_t)(val2);
8612
8684
  if (arg1) (arg1)->read_data_length = arg2;
8613
-
8614
8685
  return Qnil;
8615
8686
  fail:
8616
8687
  return Qnil;
@@ -8620,9 +8691,9 @@ fail:
8620
8691
  SWIGINTERN VALUE
8621
8692
  _wrap_MemcachedServerSt_read_data_length_get(int argc, VALUE *argv, VALUE self) {
8622
8693
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8623
- size_t result;
8624
8694
  void *argp1 = 0 ;
8625
8695
  int res1 = 0 ;
8696
+ size_t result;
8626
8697
  VALUE vresult = Qnil;
8627
8698
 
8628
8699
  if ((argc < 0) || (argc > 0)) {
@@ -8664,7 +8735,6 @@ _wrap_MemcachedServerSt_read_buffer_length_set(int argc, VALUE *argv, VALUE self
8664
8735
  }
8665
8736
  arg2 = (size_t)(val2);
8666
8737
  if (arg1) (arg1)->read_buffer_length = arg2;
8667
-
8668
8738
  return Qnil;
8669
8739
  fail:
8670
8740
  return Qnil;
@@ -8674,9 +8744,9 @@ fail:
8674
8744
  SWIGINTERN VALUE
8675
8745
  _wrap_MemcachedServerSt_read_buffer_length_get(int argc, VALUE *argv, VALUE self) {
8676
8746
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8677
- size_t result;
8678
8747
  void *argp1 = 0 ;
8679
8748
  int res1 = 0 ;
8749
+ size_t result;
8680
8750
  VALUE vresult = Qnil;
8681
8751
 
8682
8752
  if ((argc < 0) || (argc > 0)) {
@@ -8736,9 +8806,9 @@ fail:
8736
8806
  SWIGINTERN VALUE
8737
8807
  _wrap_MemcachedServerSt_read_ptr_get(int argc, VALUE *argv, VALUE self) {
8738
8808
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8739
- char *result = 0 ;
8740
8809
  void *argp1 = 0 ;
8741
8810
  int res1 = 0 ;
8811
+ char *result = 0 ;
8742
8812
  VALUE vresult = Qnil;
8743
8813
 
8744
8814
  if ((argc < 0) || (argc > 0)) {
@@ -8780,7 +8850,6 @@ _wrap_MemcachedServerSt_sockaddr_inited_set(int argc, VALUE *argv, VALUE self) {
8780
8850
  }
8781
8851
  arg2 = (memcached_allocated)(val2);
8782
8852
  if (arg1) (arg1)->sockaddr_inited = arg2;
8783
-
8784
8853
  return Qnil;
8785
8854
  fail:
8786
8855
  return Qnil;
@@ -8790,9 +8859,9 @@ fail:
8790
8859
  SWIGINTERN VALUE
8791
8860
  _wrap_MemcachedServerSt_sockaddr_inited_get(int argc, VALUE *argv, VALUE self) {
8792
8861
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8793
- memcached_allocated result;
8794
8862
  void *argp1 = 0 ;
8795
8863
  int res1 = 0 ;
8864
+ memcached_allocated result;
8796
8865
  VALUE vresult = Qnil;
8797
8866
 
8798
8867
  if ((argc < 0) || (argc > 0)) {
@@ -8834,7 +8903,6 @@ _wrap_MemcachedServerSt_address_info_set(int argc, VALUE *argv, VALUE self) {
8834
8903
  }
8835
8904
  arg2 = (struct addrinfo *)(argp2);
8836
8905
  if (arg1) (arg1)->address_info = arg2;
8837
-
8838
8906
  return Qnil;
8839
8907
  fail:
8840
8908
  return Qnil;
@@ -8844,9 +8912,9 @@ fail:
8844
8912
  SWIGINTERN VALUE
8845
8913
  _wrap_MemcachedServerSt_address_info_get(int argc, VALUE *argv, VALUE self) {
8846
8914
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8847
- struct addrinfo *result = 0 ;
8848
8915
  void *argp1 = 0 ;
8849
8916
  int res1 = 0 ;
8917
+ struct addrinfo *result = 0 ;
8850
8918
  VALUE vresult = Qnil;
8851
8919
 
8852
8920
  if ((argc < 0) || (argc > 0)) {
@@ -8888,7 +8956,6 @@ _wrap_MemcachedServerSt_type_set(int argc, VALUE *argv, VALUE self) {
8888
8956
  }
8889
8957
  arg2 = (memcached_connection)(val2);
8890
8958
  if (arg1) (arg1)->type = arg2;
8891
-
8892
8959
  return Qnil;
8893
8960
  fail:
8894
8961
  return Qnil;
@@ -8898,9 +8965,9 @@ fail:
8898
8965
  SWIGINTERN VALUE
8899
8966
  _wrap_MemcachedServerSt_type_get(int argc, VALUE *argv, VALUE self) {
8900
8967
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8901
- memcached_connection result;
8902
8968
  void *argp1 = 0 ;
8903
8969
  int res1 = 0 ;
8970
+ memcached_connection result;
8904
8971
  VALUE vresult = Qnil;
8905
8972
 
8906
8973
  if ((argc < 0) || (argc > 0)) {
@@ -8942,7 +9009,6 @@ _wrap_MemcachedServerSt_major_version_set(int argc, VALUE *argv, VALUE self) {
8942
9009
  }
8943
9010
  arg2 = (uint8_t)(val2);
8944
9011
  if (arg1) (arg1)->major_version = arg2;
8945
-
8946
9012
  return Qnil;
8947
9013
  fail:
8948
9014
  return Qnil;
@@ -8952,9 +9018,9 @@ fail:
8952
9018
  SWIGINTERN VALUE
8953
9019
  _wrap_MemcachedServerSt_major_version_get(int argc, VALUE *argv, VALUE self) {
8954
9020
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
8955
- uint8_t result;
8956
9021
  void *argp1 = 0 ;
8957
9022
  int res1 = 0 ;
9023
+ uint8_t result;
8958
9024
  VALUE vresult = Qnil;
8959
9025
 
8960
9026
  if ((argc < 0) || (argc > 0)) {
@@ -8996,7 +9062,6 @@ _wrap_MemcachedServerSt_minor_version_set(int argc, VALUE *argv, VALUE self) {
8996
9062
  }
8997
9063
  arg2 = (uint8_t)(val2);
8998
9064
  if (arg1) (arg1)->minor_version = arg2;
8999
-
9000
9065
  return Qnil;
9001
9066
  fail:
9002
9067
  return Qnil;
@@ -9006,9 +9071,9 @@ fail:
9006
9071
  SWIGINTERN VALUE
9007
9072
  _wrap_MemcachedServerSt_minor_version_get(int argc, VALUE *argv, VALUE self) {
9008
9073
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
9009
- uint8_t result;
9010
9074
  void *argp1 = 0 ;
9011
9075
  int res1 = 0 ;
9076
+ uint8_t result;
9012
9077
  VALUE vresult = Qnil;
9013
9078
 
9014
9079
  if ((argc < 0) || (argc > 0)) {
@@ -9050,7 +9115,6 @@ _wrap_MemcachedServerSt_micro_version_set(int argc, VALUE *argv, VALUE self) {
9050
9115
  }
9051
9116
  arg2 = (uint8_t)(val2);
9052
9117
  if (arg1) (arg1)->micro_version = arg2;
9053
-
9054
9118
  return Qnil;
9055
9119
  fail:
9056
9120
  return Qnil;
@@ -9060,9 +9124,9 @@ fail:
9060
9124
  SWIGINTERN VALUE
9061
9125
  _wrap_MemcachedServerSt_micro_version_get(int argc, VALUE *argv, VALUE self) {
9062
9126
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
9063
- uint8_t result;
9064
9127
  void *argp1 = 0 ;
9065
9128
  int res1 = 0 ;
9129
+ uint8_t result;
9066
9130
  VALUE vresult = Qnil;
9067
9131
 
9068
9132
  if ((argc < 0) || (argc > 0)) {
@@ -9104,7 +9168,6 @@ _wrap_MemcachedServerSt_count_set(int argc, VALUE *argv, VALUE self) {
9104
9168
  }
9105
9169
  arg2 = (uint16_t)(val2);
9106
9170
  if (arg1) (arg1)->count = arg2;
9107
-
9108
9171
  return Qnil;
9109
9172
  fail:
9110
9173
  return Qnil;
@@ -9114,9 +9177,9 @@ fail:
9114
9177
  SWIGINTERN VALUE
9115
9178
  _wrap_MemcachedServerSt_count_get(int argc, VALUE *argv, VALUE self) {
9116
9179
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
9117
- uint16_t result;
9118
9180
  void *argp1 = 0 ;
9119
9181
  int res1 = 0 ;
9182
+ uint16_t result;
9120
9183
  VALUE vresult = Qnil;
9121
9184
 
9122
9185
  if ((argc < 0) || (argc > 0)) {
@@ -9157,7 +9220,6 @@ _wrap_MemcachedServerSt_next_retry_set(int argc, VALUE *argv, VALUE self) {
9157
9220
  arg2 = NUM2LONG(rb_funcall(argv[0], rb_intern("tv_sec"), 0));
9158
9221
  }
9159
9222
  if (arg1) (arg1)->next_retry = arg2;
9160
-
9161
9223
  return Qnil;
9162
9224
  fail:
9163
9225
  return Qnil;
@@ -9167,9 +9229,9 @@ fail:
9167
9229
  SWIGINTERN VALUE
9168
9230
  _wrap_MemcachedServerSt_next_retry_get(int argc, VALUE *argv, VALUE self) {
9169
9231
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
9170
- time_t result;
9171
9232
  void *argp1 = 0 ;
9172
9233
  int res1 = 0 ;
9234
+ time_t result;
9173
9235
  VALUE vresult = Qnil;
9174
9236
 
9175
9237
  if ((argc < 0) || (argc > 0)) {
@@ -9213,7 +9275,6 @@ _wrap_MemcachedServerSt_root_set(int argc, VALUE *argv, VALUE self) {
9213
9275
  }
9214
9276
  arg2 = (memcached_st *)(argp2);
9215
9277
  if (arg1) (arg1)->root = arg2;
9216
-
9217
9278
  return Qnil;
9218
9279
  fail:
9219
9280
  return Qnil;
@@ -9223,9 +9284,9 @@ fail:
9223
9284
  SWIGINTERN VALUE
9224
9285
  _wrap_MemcachedServerSt_root_get(int argc, VALUE *argv, VALUE self) {
9225
9286
  struct memcached_server_st *arg1 = (struct memcached_server_st *) 0 ;
9226
- memcached_st *result = 0 ;
9227
9287
  void *argp1 = 0 ;
9228
9288
  int res1 = 0 ;
9289
+ memcached_st *result = 0 ;
9229
9290
  VALUE vresult = Qnil;
9230
9291
 
9231
9292
  if ((argc < 0) || (argc > 0)) {
@@ -9268,8 +9329,8 @@ _wrap_new_MemcachedServerSt(int argc, VALUE *argv, VALUE self) {
9268
9329
  if ((argc < 0) || (argc > 0)) {
9269
9330
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
9270
9331
  }
9271
- result = (struct memcached_server_st *)(struct memcached_server_st *) calloc(1, sizeof(struct memcached_server_st));DATA_PTR(self) = result;
9272
-
9332
+ result = (struct memcached_server_st *)calloc(1, sizeof(struct memcached_server_st));
9333
+ DATA_PTR(self) = result;
9273
9334
  return self;
9274
9335
  fail:
9275
9336
  return Qnil;
@@ -9281,34 +9342,6 @@ free_memcached_server_st(struct memcached_server_st *arg1) {
9281
9342
  free((char *) arg1);
9282
9343
  }
9283
9344
 
9284
- SWIGINTERN VALUE
9285
- _wrap_ns(int argc, VALUE *argv, VALUE self) {
9286
- char *arg1 = (char *) 0 ;
9287
- size_t arg2 ;
9288
- char *arg3 = (char *) 0 ;
9289
- size_t arg4 ;
9290
- VALUE result;
9291
- VALUE vresult = Qnil;
9292
-
9293
- if ((argc < 2) || (argc > 2)) {
9294
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
9295
- }
9296
- {
9297
- arg1 = STR2CSTR(argv[0]);
9298
- arg2 = (size_t) RSTRING(argv[0])->len;
9299
- }
9300
- {
9301
- arg3 = STR2CSTR(argv[1]);
9302
- arg4 = (size_t) RSTRING(argv[1])->len;
9303
- }
9304
- result = (VALUE)ns(arg1,arg2,arg3,arg4);
9305
- vresult = result;
9306
- return vresult;
9307
- fail:
9308
- return Qnil;
9309
- }
9310
-
9311
-
9312
9345
  SWIGINTERN VALUE
9313
9346
  _wrap_memcached_get_rvalue(int argc, VALUE *argv, VALUE self) {
9314
9347
  memcached_st *arg1 = (memcached_st *) 0 ;
@@ -9316,13 +9349,13 @@ _wrap_memcached_get_rvalue(int argc, VALUE *argv, VALUE self) {
9316
9349
  size_t arg3 ;
9317
9350
  uint32_t *arg4 = (uint32_t *) 0 ;
9318
9351
  memcached_return *arg5 = (memcached_return *) 0 ;
9319
- VALUE result;
9320
9352
  void *argp1 = 0 ;
9321
9353
  int res1 = 0 ;
9322
9354
  uint32_t temp4 ;
9323
9355
  int res4 = SWIG_TMPOBJ ;
9324
9356
  memcached_return temp5 ;
9325
9357
  int res5 = SWIG_TMPOBJ ;
9358
+ VALUE result;
9326
9359
  VALUE vresult = Qnil;
9327
9360
 
9328
9361
  arg4 = &temp4;
@@ -9339,7 +9372,7 @@ _wrap_memcached_get_rvalue(int argc, VALUE *argv, VALUE self) {
9339
9372
  arg2 = STR2CSTR(argv[1]);
9340
9373
  arg3 = (size_t) RSTRING(argv[1])->len;
9341
9374
  }
9342
- result = (VALUE)memcached_get_rvalue(arg1,arg2,arg3,arg4,arg5);
9375
+ result = (VALUE)memcached_get_rvalue(arg1,(char const *)arg2,arg3,arg4,arg5);
9343
9376
  vresult = result;
9344
9377
  if (SWIG_IsTmpObj(res4)) {
9345
9378
  vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_unsigned_SS_int((*arg4)));
@@ -9366,13 +9399,13 @@ _wrap_memcached_fetch_rvalue(int argc, VALUE *argv, VALUE self) {
9366
9399
  size_t *arg3 = (size_t *) 0 ;
9367
9400
  uint32_t *arg4 = (uint32_t *) 0 ;
9368
9401
  memcached_return *arg5 = (memcached_return *) 0 ;
9369
- VALUE result;
9370
9402
  void *argp1 = 0 ;
9371
9403
  int res1 = 0 ;
9372
9404
  uint32_t temp4 ;
9373
9405
  int res4 = SWIG_TMPOBJ ;
9374
9406
  memcached_return temp5 ;
9375
9407
  int res5 = SWIG_TMPOBJ ;
9408
+ VALUE result;
9376
9409
  VALUE vresult = Qnil;
9377
9410
 
9378
9411
  {
@@ -9421,7 +9454,6 @@ _wrap_memcached_stat_get_rvalue(int argc, VALUE *argv, VALUE self) {
9421
9454
  memcached_stat_st *arg2 = (memcached_stat_st *) 0 ;
9422
9455
  char *arg3 = (char *) 0 ;
9423
9456
  memcached_return *arg4 = (memcached_return *) 0 ;
9424
- VALUE result;
9425
9457
  void *argp1 = 0 ;
9426
9458
  int res1 = 0 ;
9427
9459
  void *argp2 = 0 ;
@@ -9431,6 +9463,7 @@ _wrap_memcached_stat_get_rvalue(int argc, VALUE *argv, VALUE self) {
9431
9463
  int alloc3 = 0 ;
9432
9464
  memcached_return temp4 ;
9433
9465
  int res4 = SWIG_TMPOBJ ;
9466
+ VALUE result;
9434
9467
  VALUE vresult = Qnil;
9435
9468
 
9436
9469
  arg4 = &temp4;
@@ -9472,11 +9505,11 @@ SWIGINTERN VALUE
9472
9505
  _wrap_memcached_select_server_at(int argc, VALUE *argv, VALUE self) {
9473
9506
  memcached_st *arg1 = (memcached_st *) 0 ;
9474
9507
  int arg2 ;
9475
- memcached_server_st *result = 0 ;
9476
9508
  void *argp1 = 0 ;
9477
9509
  int res1 = 0 ;
9478
9510
  int val2 ;
9479
9511
  int ecode2 = 0 ;
9512
+ memcached_server_st *result = 0 ;
9480
9513
  VALUE vresult = Qnil;
9481
9514
 
9482
9515
  if ((argc < 2) || (argc > 2)) {
@@ -9505,13 +9538,13 @@ _wrap_memcached_select_stat_at(int argc, VALUE *argv, VALUE self) {
9505
9538
  memcached_st *arg1 = (memcached_st *) 0 ;
9506
9539
  memcached_stat_st *arg2 = (memcached_stat_st *) 0 ;
9507
9540
  int arg3 ;
9508
- memcached_stat_st *result = 0 ;
9509
9541
  void *argp1 = 0 ;
9510
9542
  int res1 = 0 ;
9511
9543
  void *argp2 = 0 ;
9512
9544
  int res2 = 0 ;
9513
9545
  int val3 ;
9514
9546
  int ecode3 = 0 ;
9547
+ memcached_stat_st *result = 0 ;
9515
9548
  VALUE vresult = Qnil;
9516
9549
 
9517
9550
  if ((argc < 3) || (argc > 3)) {
@@ -9540,36 +9573,6 @@ fail:
9540
9573
  }
9541
9574
 
9542
9575
 
9543
- SWIGINTERN VALUE
9544
- _wrap_memcached_generate_hash(int argc, VALUE *argv, VALUE self) {
9545
- memcached_st *arg1 = (memcached_st *) 0 ;
9546
- char *arg2 = (char *) 0 ;
9547
- size_t arg3 ;
9548
- unsigned int result;
9549
- void *argp1 = 0 ;
9550
- int res1 = 0 ;
9551
- VALUE vresult = Qnil;
9552
-
9553
- if ((argc < 2) || (argc > 2)) {
9554
- rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
9555
- }
9556
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_memcached_st, 0 | 0 );
9557
- if (!SWIG_IsOK(res1)) {
9558
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "memcached_st *","memcached_generate_hash", 1, argv[0] ));
9559
- }
9560
- arg1 = (memcached_st *)(argp1);
9561
- {
9562
- arg2 = STR2CSTR(argv[1]);
9563
- arg3 = (size_t) RSTRING(argv[1])->len;
9564
- }
9565
- result = (unsigned int)memcached_generate_hash(arg1,arg2,arg3);
9566
- vresult = SWIG_From_unsigned_SS_int((unsigned int)(result));
9567
- return vresult;
9568
- fail:
9569
- return Qnil;
9570
- }
9571
-
9572
-
9573
9576
 
9574
9577
  /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
9575
9578
 
@@ -9769,7 +9772,7 @@ SWIGRUNTIME void
9769
9772
  SWIG_InitializeModule(void *clientdata) {
9770
9773
  size_t i;
9771
9774
  swig_module_info *module_head, *iter;
9772
- int found;
9775
+ int found, init;
9773
9776
 
9774
9777
  clientdata = clientdata;
9775
9778
 
@@ -9779,6 +9782,9 @@ SWIG_InitializeModule(void *clientdata) {
9779
9782
  swig_module.type_initial = swig_type_initial;
9780
9783
  swig_module.cast_initial = swig_cast_initial;
9781
9784
  swig_module.next = &swig_module;
9785
+ init = 1;
9786
+ } else {
9787
+ init = 0;
9782
9788
  }
9783
9789
 
9784
9790
  /* Try and load any already created modules */
@@ -9807,6 +9813,12 @@ SWIG_InitializeModule(void *clientdata) {
9807
9813
  module_head->next = &swig_module;
9808
9814
  }
9809
9815
 
9816
+ /* When multiple interpeters are used, a module could have already been initialized in
9817
+ a different interpreter, but not yet have a pointer in this interpreter.
9818
+ In this case, we do not want to continue adding types... everything should be
9819
+ set up already */
9820
+ if (init == 0) return;
9821
+
9810
9822
  /* Now work on filling in swig_module.types */
9811
9823
  #ifdef SWIGRUNTIME_DEBUG
9812
9824
  printf("SWIG_InitializeModule: size %d\n", swig_module.size);
@@ -9971,7 +9983,7 @@ SWIGEXPORT void Init_rlibmemcached(void) {
9971
9983
  cMemcachedContinuumItemSt.mark = 0;
9972
9984
  cMemcachedContinuumItemSt.destroy = (void (*)(void *)) free_memcached_continuum_item_st;
9973
9985
  cMemcachedContinuumItemSt.trackObjects = 0;
9974
- rb_define_const(mRlibmemcached, "LIBMEMCACHED_VERSION_STRING", SWIG_FromCharPtr("0.20"));
9986
+ rb_define_const(mRlibmemcached, "LIBMEMCACHED_VERSION_STRING", SWIG_FromCharPtr("0.22"));
9975
9987
 
9976
9988
  cMemcachedStatSt.klass = rb_define_class_under(mRlibmemcached, "MemcachedStatSt", rb_cObject);
9977
9989
  SWIG_TypeClientData(SWIGTYPE_p_memcached_stat_st, (void *) &cMemcachedStatSt);
@@ -10085,8 +10097,12 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10085
10097
  rb_define_method(cMemcachedSt.klass, "get_key_failure", _wrap_MemcachedSt_get_key_failure_get, -1);
10086
10098
  rb_define_method(cMemcachedSt.klass, "delete_trigger=", _wrap_MemcachedSt_delete_trigger_set, -1);
10087
10099
  rb_define_method(cMemcachedSt.klass, "delete_trigger", _wrap_MemcachedSt_delete_trigger_get, -1);
10100
+ rb_define_method(cMemcachedSt.klass, "prefix_key=", _wrap_MemcachedSt_prefix_key_set, -1);
10101
+ rb_define_method(cMemcachedSt.klass, "prefix_key", _wrap_MemcachedSt_prefix_key_get, -1);
10102
+ rb_define_method(cMemcachedSt.klass, "prefix_key_length=", _wrap_MemcachedSt_prefix_key_length_set, -1);
10103
+ rb_define_method(cMemcachedSt.klass, "prefix_key_length", _wrap_MemcachedSt_prefix_key_length_get, -1);
10088
10104
  cMemcachedSt.mark = 0;
10089
- cMemcachedSt.destroy = (void (*)(void *)) free_memcached_st;
10105
+ cMemcachedSt.destroy = (void (*)(void *)) memcached_free;
10090
10106
  cMemcachedSt.trackObjects = 0;
10091
10107
  rb_define_module_function(mRlibmemcached, "memcached_lib_version", _wrap_memcached_lib_version, -1);
10092
10108
  rb_define_module_function(mRlibmemcached, "memcached_create", _wrap_memcached_create, -1);
@@ -10104,10 +10120,6 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10104
10120
  rb_define_module_function(mRlibmemcached, "memcached_strerror", _wrap_memcached_strerror, -1);
10105
10121
  rb_define_module_function(mRlibmemcached, "memcached_behavior_set", _wrap_memcached_behavior_set, -1);
10106
10122
  rb_define_module_function(mRlibmemcached, "memcached_behavior_get", _wrap_memcached_behavior_get, -1);
10107
- rb_define_module_function(mRlibmemcached, "memcached_get", _wrap_memcached_get, -1);
10108
- rb_define_module_function(mRlibmemcached, "memcached_mget", _wrap_memcached_mget, -1);
10109
- rb_define_module_function(mRlibmemcached, "memcached_fetch", _wrap_memcached_fetch, -1);
10110
- rb_define_module_function(mRlibmemcached, "memcached_fetch_result", _wrap_memcached_fetch_result, -1);
10111
10123
  rb_define_module_function(mRlibmemcached, "memcached_server_add_udp", _wrap_memcached_server_add_udp, -1);
10112
10124
  rb_define_module_function(mRlibmemcached, "memcached_server_add_unix_socket", _wrap_memcached_server_add_unix_socket, -1);
10113
10125
  rb_define_module_function(mRlibmemcached, "memcached_server_add", _wrap_memcached_server_add, -1);
@@ -10118,8 +10130,6 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10118
10130
  rb_define_module_function(mRlibmemcached, "memcached_servers_parse", _wrap_memcached_servers_parse, -1);
10119
10131
  rb_define_module_function(mRlibmemcached, "memcached_stat_get_value", _wrap_memcached_stat_get_value, -1);
10120
10132
  rb_define_module_function(mRlibmemcached, "memcached_stat_get_keys", _wrap_memcached_stat_get_keys, -1);
10121
- rb_define_module_function(mRlibmemcached, "memcached_get_by_key", _wrap_memcached_get_by_key, -1);
10122
- rb_define_module_function(mRlibmemcached, "memcached_mget_by_key", _wrap_memcached_mget_by_key, -1);
10123
10133
  rb_define_module_function(mRlibmemcached, "memcached_delete_by_key", _wrap_memcached_delete_by_key, -1);
10124
10134
  rb_define_module_function(mRlibmemcached, "memcached_fetch_execute", _wrap_memcached_fetch_execute, -1);
10125
10135
  rb_define_module_function(mRlibmemcached, "memcached_callback_set", _wrap_memcached_callback_set, -1);
@@ -10135,6 +10145,7 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10135
10145
  rb_define_const(mRlibmemcached, "MEMCACHED_STRIDE", SWIG_From_int((int)(4)));
10136
10146
  rb_define_const(mRlibmemcached, "MEMCACHED_DEFAULT_TIMEOUT", SWIG_From_int((int)(1000)));
10137
10147
  rb_define_const(mRlibmemcached, "MEMCACHED_CONTINUUM_ADDITION", SWIG_From_int((int)(10)));
10148
+ rb_define_const(mRlibmemcached, "MEMCACHED_PREFIX_KEY_MAX_SIZE", SWIG_From_int((int)(12)));
10138
10149
  rb_define_const(mRlibmemcached, "MEMCACHED_SUCCESS", SWIG_From_int((int)(MEMCACHED_SUCCESS)));
10139
10150
  rb_define_const(mRlibmemcached, "MEMCACHED_FAILURE", SWIG_From_int((int)(MEMCACHED_FAILURE)));
10140
10151
  rb_define_const(mRlibmemcached, "MEMCACHED_HOST_LOOKUP_FAILURE", SWIG_From_int((int)(MEMCACHED_HOST_LOOKUP_FAILURE)));
@@ -10189,6 +10200,7 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10189
10200
  rb_define_const(mRlibmemcached, "MEMCACHED_BEHAVIOR_VERIFY_KEY", SWIG_From_int((int)(MEMCACHED_BEHAVIOR_VERIFY_KEY)));
10190
10201
  rb_define_const(mRlibmemcached, "MEMCACHED_BEHAVIOR_CONNECT_TIMEOUT", SWIG_From_int((int)(MEMCACHED_BEHAVIOR_CONNECT_TIMEOUT)));
10191
10202
  rb_define_const(mRlibmemcached, "MEMCACHED_BEHAVIOR_RETRY_TIMEOUT", SWIG_From_int((int)(MEMCACHED_BEHAVIOR_RETRY_TIMEOUT)));
10203
+ rb_define_const(mRlibmemcached, "MEMCACHED_CALLBACK_PREFIX_KEY", SWIG_From_int((int)(MEMCACHED_CALLBACK_PREFIX_KEY)));
10192
10204
  rb_define_const(mRlibmemcached, "MEMCACHED_CALLBACK_USER_DATA", SWIG_From_int((int)(MEMCACHED_CALLBACK_USER_DATA)));
10193
10205
  rb_define_const(mRlibmemcached, "MEMCACHED_CALLBACK_CLEANUP_FUNCTION", SWIG_From_int((int)(MEMCACHED_CALLBACK_CLEANUP_FUNCTION)));
10194
10206
  rb_define_const(mRlibmemcached, "MEMCACHED_CALLBACK_CLONE_FUNCTION", SWIG_From_int((int)(MEMCACHED_CALLBACK_CLONE_FUNCTION)));
@@ -10213,6 +10225,12 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10213
10225
  rb_define_const(mRlibmemcached, "MEMCACHED_NOT_ALLOCATED", SWIG_From_int((int)(MEMCACHED_NOT_ALLOCATED)));
10214
10226
  rb_define_const(mRlibmemcached, "MEMCACHED_ALLOCATED", SWIG_From_int((int)(MEMCACHED_ALLOCATED)));
10215
10227
  rb_define_const(mRlibmemcached, "MEMCACHED_USED", SWIG_From_int((int)(MEMCACHED_USED)));
10228
+ rb_define_module_function(mRlibmemcached, "memcached_get", _wrap_memcached_get, -1);
10229
+ rb_define_module_function(mRlibmemcached, "memcached_mget", _wrap_memcached_mget, -1);
10230
+ rb_define_module_function(mRlibmemcached, "memcached_get_by_key", _wrap_memcached_get_by_key, -1);
10231
+ rb_define_module_function(mRlibmemcached, "memcached_mget_by_key", _wrap_memcached_mget_by_key, -1);
10232
+ rb_define_module_function(mRlibmemcached, "memcached_fetch", _wrap_memcached_fetch, -1);
10233
+ rb_define_module_function(mRlibmemcached, "memcached_fetch_result", _wrap_memcached_fetch_result, -1);
10216
10234
  rb_define_module_function(mRlibmemcached, "memcached_set", _wrap_memcached_set, -1);
10217
10235
  rb_define_module_function(mRlibmemcached, "memcached_add", _wrap_memcached_add, -1);
10218
10236
  rb_define_module_function(mRlibmemcached, "memcached_replace", _wrap_memcached_replace, -1);
@@ -10303,12 +10321,10 @@ SWIGEXPORT void Init_rlibmemcached(void) {
10303
10321
  cMemcachedServerSt.mark = 0;
10304
10322
  cMemcachedServerSt.destroy = (void (*)(void *)) free_memcached_server_st;
10305
10323
  cMemcachedServerSt.trackObjects = 0;
10306
- rb_define_module_function(mRlibmemcached, "ns", _wrap_ns, -1);
10307
10324
  rb_define_module_function(mRlibmemcached, "memcached_get_rvalue", _wrap_memcached_get_rvalue, -1);
10308
10325
  rb_define_module_function(mRlibmemcached, "memcached_fetch_rvalue", _wrap_memcached_fetch_rvalue, -1);
10309
10326
  rb_define_module_function(mRlibmemcached, "memcached_stat_get_rvalue", _wrap_memcached_stat_get_rvalue, -1);
10310
10327
  rb_define_module_function(mRlibmemcached, "memcached_select_server_at", _wrap_memcached_select_server_at, -1);
10311
10328
  rb_define_module_function(mRlibmemcached, "memcached_select_stat_at", _wrap_memcached_select_stat_at, -1);
10312
- rb_define_module_function(mRlibmemcached, "memcached_generate_hash", _wrap_memcached_generate_hash, -1);
10313
10329
  }
10314
10330