Method: Ctp::CThostFtdcInvestorProductGroupMarginField#BrokerID=

Defined in:
ext/ctp/ctp.cxx

#BrokerID=(*args) ⇒ Object



132621
132622
132623
132624
132625
132626
132627
132628
132629
132630
132631
132632
132633
132634
132635
132636
132637
132638
132639
132640
132641
132642
132643
132644
132645
132646
132647
132648
# File 'ext/ctp/ctp.cxx', line 132621

SWIGINTERN VALUE
_wrap_CThostFtdcInvestorProductGroupMarginField_BrokerID_set(int argc, VALUE *argv, VALUE self) {
  CThostFtdcInvestorProductGroupMarginField *arg1 = (CThostFtdcInvestorProductGroupMarginField *) 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_CThostFtdcInvestorProductGroupMarginField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CThostFtdcInvestorProductGroupMarginField *","BrokerID", 1, self )); 
  }
  arg1 = reinterpret_cast< CThostFtdcInvestorProductGroupMarginField * >(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;
}