Class: IOU::OpCtx

Inherits:
Object
  • Object
show all
Defined in:
ext/iou/op_ctx.c

Instance Method Summary collapse

Constructor Details

#initialize(spec, proc) ⇒ Object



33
34
35
36
37
38
39
40
# File 'ext/iou/op_ctx.c', line 33

VALUE OpCtx_initialize(VALUE self, VALUE spec, VALUE proc) {
  OpCtx_t *osd = RTYPEDDATA_DATA(self);
  RB_OBJ_WRITE(self, &osd->spec, spec);
  RB_OBJ_WRITE(self, &osd->proc, proc);
  memset(&osd->data, 0, sizeof(osd->data));
  osd->stop_signal = 0;
  return self;
}

Instance Method Details

#specObject



42
43
44
45
# File 'ext/iou/op_ctx.c', line 42

VALUE OpCtx_spec(VALUE self) {
  OpCtx_t *osd = RTYPEDDATA_DATA(self);
  return osd->spec;
}