class Cproton::Pn_rbkey_t

Public Class Methods

new(*args) click to toggle source
SWIGINTERN VALUE
_wrap_new_Pn_rbkey_t(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *result = 0 ;
  
  if ((argc < 0) || (argc > 0)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
  }
  result = (Pn_rbkey_t *)calloc(1, sizeof(Pn_rbkey_t));
  DATA_PTR(self) = result;
  return self;
fail:
  return Qnil;
}

Public Instance Methods

key_value(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_key_value_get(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char *result = 0 ;
  VALUE vresult = Qnil;
  
  if ((argc < 0) || (argc > 0)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","key_value", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  result = (char *) ((arg1)->key_value);
  vresult = SWIG_FromCharPtr((const char *)result);
  return vresult;
fail:
  return Qnil;
}
key_value=(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_key_value_set(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  
  if ((argc < 1) || (argc > 1)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","key_value", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","key_value", 2, argv[0] ));
  }
  arg2 = (char *)(buf2);
  if (arg1->key_value) free((char*)arg1->key_value);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->key_value = (char *)(char *)memcpy((char *)malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->key_value = 0;
  }
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return Qnil;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return Qnil;
}
method(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_method_get(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char *result = 0 ;
  VALUE vresult = Qnil;
  
  if ((argc < 0) || (argc > 0)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","method", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  result = (char *) ((arg1)->method);
  vresult = SWIG_FromCharPtr((const char *)result);
  return vresult;
fail:
  return Qnil;
}
method=(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_method_set(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  
  if ((argc < 1) || (argc > 1)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","method", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *","method", 2, argv[0] ));
  }
  arg2 = (char *)(buf2);
  if (arg1->method) free((char*)arg1->method);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->method = (char *)(char *)memcpy((char *)malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->method = 0;
  }
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return Qnil;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return Qnil;
}
registry(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_registry_get(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *result = 0 ;
  VALUE vresult = Qnil;
  
  if ((argc < 0) || (argc > 0)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","registry", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  result = (void *) ((arg1)->registry);
  vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return vresult;
fail:
  return Qnil;
}
registry=(*args) click to toggle source
SWIGINTERN VALUE
_wrap_Pn_rbkey_t_registry_set(int argc, VALUE *argv, VALUE self) {
  Pn_rbkey_t *arg1 = (Pn_rbkey_t *) 0 ;
  void *arg2 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  
  if ((argc < 1) || (argc > 1)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
  }
  res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_Pn_rbkey_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Pn_rbkey_t *","registry", 1, self )); 
  }
  arg1 = (Pn_rbkey_t *)(argp1);
  res2 = SWIG_ConvertPtr(argv[0],SWIG_as_voidptrptr(&arg2), 0, SWIG_POINTER_DISOWN);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "void *","registry", 2, argv[0] )); 
  }
  if (arg1) (arg1)->registry = arg2;
  return Qnil;
fail:
  return Qnil;
}