class SysVIPC::Semid_ds
Public Class Methods
new(*args)
click to toggle source
SWIGINTERN VALUE _wrap_new_semid_ds(int argc, VALUE *argv, VALUE self) { struct semid_ds *result = 0 ; if ((argc < 0) || (argc > 0)) { rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail; } result = (struct semid_ds *)calloc(1, sizeof(struct semid_ds)); DATA_PTR(self) = result; return self; fail: return Qnil; }
Public Instance Methods
sem_ctime(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_ctime_get(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; void *argp1 = 0 ; int res1 = 0 ; time_t result; 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_ctime", 1, self )); } arg1 = (struct semid_ds *)(argp1); result = (time_t) ((arg1)->sem_ctime); { vresult = rb_time_new(result, 0); } return vresult; fail: return Qnil; }
sem_ctime=(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_ctime_set(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; time_t arg2 ; void *argp1 = 0 ; int res1 = 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_ctime", 1, self )); } arg1 = (struct semid_ds *)(argp1); { if (NIL_P(argv[0])) arg2 = (time_t)-1; else arg2 = NUM2LONG(rb_funcall(argv[0], rb_intern("tv_sec"), 0)); } if (arg1) (arg1)->sem_ctime = arg2; return Qnil; fail: return Qnil; }
sem_nsems(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_nsems_get(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; void *argp1 = 0 ; int res1 = 0 ; unsigned short result; 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_nsems", 1, self )); } arg1 = (struct semid_ds *)(argp1); result = (unsigned short) ((arg1)->sem_nsems); vresult = SWIG_From_unsigned_SS_short((unsigned short)(result)); return vresult; fail: return Qnil; }
sem_nsems=(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_nsems_set(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; unsigned short arg2 ; void *argp1 = 0 ; int res1 = 0 ; unsigned short val2 ; int ecode2 = 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_nsems", 1, self )); } arg1 = (struct semid_ds *)(argp1); ecode2 = SWIG_AsVal_unsigned_SS_short(argv[0], &val2); if (!SWIG_IsOK(ecode2)) { SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "unsigned short","sem_nsems", 2, argv[0] )); } arg2 = (unsigned short)(val2); if (arg1) (arg1)->sem_nsems = arg2; return Qnil; fail: return Qnil; }
sem_otime(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_otime_get(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; void *argp1 = 0 ; int res1 = 0 ; time_t result; 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_otime", 1, self )); } arg1 = (struct semid_ds *)(argp1); result = (time_t) ((arg1)->sem_otime); { vresult = rb_time_new(result, 0); } return vresult; fail: return Qnil; }
sem_otime=(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_otime_set(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; time_t arg2 ; void *argp1 = 0 ; int res1 = 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_otime", 1, self )); } arg1 = (struct semid_ds *)(argp1); { if (NIL_P(argv[0])) arg2 = (time_t)-1; else arg2 = NUM2LONG(rb_funcall(argv[0], rb_intern("tv_sec"), 0)); } if (arg1) (arg1)->sem_otime = arg2; return Qnil; fail: return Qnil; }
sem_perm(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_perm_get(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; void *argp1 = 0 ; int res1 = 0 ; struct ipc_perm *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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_perm", 1, self )); } arg1 = (struct semid_ds *)(argp1); result = (struct ipc_perm *)& ((arg1)->sem_perm); vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ipc_perm, 0 | 0 ); return vresult; fail: return Qnil; }
sem_perm=(*args)
click to toggle source
SWIGINTERN VALUE _wrap_semid_ds_sem_perm_set(int argc, VALUE *argv, VALUE self) { struct semid_ds *arg1 = (struct semid_ds *) 0 ; struct ipc_perm *arg2 = (struct ipc_perm *) 0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 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_semid_ds, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "struct semid_ds *","sem_perm", 1, self )); } arg1 = (struct semid_ds *)(argp1); res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_ipc_perm, 0 | 0 ); if (!SWIG_IsOK(res2)) { SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "struct ipc_perm *","sem_perm", 2, argv[0] )); } arg2 = (struct ipc_perm *)(argp2); if (arg1) (arg1)->sem_perm = *arg2; return Qnil; fail: return Qnil; }