Class: Ctp::CThostFtdcMarginModelField

Inherits:
Object
  • Object
show all
Defined in:
ext/ctp/ctp.cxx

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ Object



131329
131330
131331
131332
131333
131334
131335
131336
131337
131338
131339
131340
131341
131342
# File 'ext/ctp/ctp.cxx', line 131329

SWIGINTERN VALUE
_wrap_new_CThostFtdcMarginModelField(int argc, VALUE *argv, VALUE self) {
  const char *classname SWIGUNUSED = "Ctp::CThostFtdcMarginModelField";
  CThostFtdcMarginModelField *result = 0 ;
  
  if ((argc < 0) || (argc > 0)) {
    rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
  }
  result = (CThostFtdcMarginModelField *)new CThostFtdcMarginModelField();
  DATA_PTR(self) = result;
  return self;
fail:
  return Qnil;
}

Instance Method Details

#BrokerID(*args) ⇒ Object



131164
131165
131166
131167
131168
131169
131170
131171
131172
131173
131174
131175
131176
131177
131178
131179
131180
131181
131182
131183
131184
131185
131186
131187
131188
131189
131190
131191
# File 'ext/ctp/ctp.cxx', line 131164

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_BrokerID_get(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","BrokerID", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  result = (char *) ((arg1)->BrokerID);
  {
    size_t size = SWIG_strnlen(result, 11);
    
    
    
    vresult = SWIG_FromCharPtrAndSize(result, size);
  }
  return vresult;
fail:
  return Qnil;
}

#BrokerID=(*args) ⇒ Object



131134
131135
131136
131137
131138
131139
131140
131141
131142
131143
131144
131145
131146
131147
131148
131149
131150
131151
131152
131153
131154
131155
131156
131157
131158
131159
131160
131161
# File 'ext/ctp/ctp.cxx', line 131134

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_BrokerID_set(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[11] ;
  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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","BrokerID", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  res2 = SWIG_AsCharArray(argv[0], temp2, 11);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char [11]","BrokerID", 2, argv[0] ));
  }
  arg2 = reinterpret_cast< char * >(temp2);
  if (arg2) memcpy(arg1->BrokerID,arg2,11*sizeof(char));
  else memset(arg1->BrokerID,0,11*sizeof(char));
  return Qnil;
fail:
  return Qnil;
}

#MarginModelID(*args) ⇒ Object



131224
131225
131226
131227
131228
131229
131230
131231
131232
131233
131234
131235
131236
131237
131238
131239
131240
131241
131242
131243
131244
131245
131246
131247
131248
131249
131250
131251
# File 'ext/ctp/ctp.cxx', line 131224

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_MarginModelID_get(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","MarginModelID", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  result = (char *) ((arg1)->MarginModelID);
  {
    size_t size = SWIG_strnlen(result, 13);
    
    
    
    vresult = SWIG_FromCharPtrAndSize(result, size);
  }
  return vresult;
fail:
  return Qnil;
}

#MarginModelID=(*args) ⇒ Object



131194
131195
131196
131197
131198
131199
131200
131201
131202
131203
131204
131205
131206
131207
131208
131209
131210
131211
131212
131213
131214
131215
131216
131217
131218
131219
131220
131221
# File 'ext/ctp/ctp.cxx', line 131194

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_MarginModelID_set(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[13] ;
  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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","MarginModelID", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  res2 = SWIG_AsCharArray(argv[0], temp2, 13);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char [13]","MarginModelID", 2, argv[0] ));
  }
  arg2 = reinterpret_cast< char * >(temp2);
  if (arg2) memcpy(arg1->MarginModelID,arg2,13*sizeof(char));
  else memset(arg1->MarginModelID,0,13*sizeof(char));
  return Qnil;
fail:
  return Qnil;
}

#MarginModelName(*args) ⇒ Object



131284
131285
131286
131287
131288
131289
131290
131291
131292
131293
131294
131295
131296
131297
131298
131299
131300
131301
131302
131303
131304
131305
131306
131307
131308
131309
131310
131311
# File 'ext/ctp/ctp.cxx', line 131284

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_MarginModelName_get(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","MarginModelName", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  result = (char *) ((arg1)->MarginModelName);
  {
    size_t size = SWIG_strnlen(result, 161);
    
    
    
    vresult = SWIG_FromCharPtrAndSize(result, size);
  }
  return vresult;
fail:
  return Qnil;
}

#MarginModelName=(*args) ⇒ Object



131254
131255
131256
131257
131258
131259
131260
131261
131262
131263
131264
131265
131266
131267
131268
131269
131270
131271
131272
131273
131274
131275
131276
131277
131278
131279
131280
131281
# File 'ext/ctp/ctp.cxx', line 131254

SWIGINTERN VALUE
_wrap_CThostFtdcMarginModelField_MarginModelName_set(int argc, VALUE *argv, VALUE self) {
  CThostFtdcMarginModelField *arg1 = (CThostFtdcMarginModelField *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[161] ;
  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_CThostFtdcMarginModelField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcMarginModelField *","MarginModelName", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcMarginModelField * >(argp1);
  res2 = SWIG_AsCharArray(argv[0], temp2, 161);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char [161]","MarginModelName", 2, argv[0] ));
  }
  arg2 = reinterpret_cast< char * >(temp2);
  if (arg2) memcpy(arg1->MarginModelName,arg2,161*sizeof(char));
  else memset(arg1->MarginModelName,0,161*sizeof(char));
  return Qnil;
fail:
  return Qnil;
}