Class: Ctp::CThostFtdcBrokerSyncField
- Inherits:
-
Object
- Object
- Ctp::CThostFtdcBrokerSyncField
- Defined in:
- ext/ctp/ctp.cxx
Instance Method Summary collapse
Constructor Details
#initialize(*args) ⇒ Object
49430 49431 49432 49433 49434 49435 49436 49437 49438 49439 49440 49441 49442 49443 |
# File 'ext/ctp/ctp.cxx', line 49430
SWIGINTERN VALUE
_wrap_new_CThostFtdcBrokerSyncField(int argc, VALUE *argv, VALUE self) {
const char *classname SWIGUNUSED = "Ctp::CThostFtdcBrokerSyncField";
CThostFtdcBrokerSyncField *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
result = (CThostFtdcBrokerSyncField *)new CThostFtdcBrokerSyncField();
DATA_PTR(self) = result;
return self;
fail:
return Qnil;
}
|
Instance Method Details
#BrokerID(*args) ⇒ Object
49385 49386 49387 49388 49389 49390 49391 49392 49393 49394 49395 49396 49397 49398 49399 49400 49401 49402 49403 49404 49405 49406 49407 49408 49409 49410 49411 49412 |
# File 'ext/ctp/ctp.cxx', line 49385
SWIGINTERN VALUE
_wrap_CThostFtdcBrokerSyncField_BrokerID_get(int argc, VALUE *argv, VALUE self) {
CThostFtdcBrokerSyncField *arg1 = (CThostFtdcBrokerSyncField *) 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_CThostFtdcBrokerSyncField, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcBrokerSyncField *","BrokerID", 1, self ));
}
arg1 = reinterpret_cast< CThostFtdcBrokerSyncField * >(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
49355 49356 49357 49358 49359 49360 49361 49362 49363 49364 49365 49366 49367 49368 49369 49370 49371 49372 49373 49374 49375 49376 49377 49378 49379 49380 49381 49382 |
# File 'ext/ctp/ctp.cxx', line 49355
SWIGINTERN VALUE
_wrap_CThostFtdcBrokerSyncField_BrokerID_set(int argc, VALUE *argv, VALUE self) {
CThostFtdcBrokerSyncField *arg1 = (CThostFtdcBrokerSyncField *) 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_CThostFtdcBrokerSyncField, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcBrokerSyncField *","BrokerID", 1, self ));
}
arg1 = reinterpret_cast< CThostFtdcBrokerSyncField * >(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;
}
|