Class: Quickfix::CharField

Inherits:
((swig_class *) SWIGTYPE_p_FIX__FieldBase->clientdata)->klass
  • Object
show all
Defined in:
ext/quickfix/QuickfixRuby.cpp

Instance Method Summary collapse

Constructor Details

#initialize(*args, self) ⇒ Object



11848
11849
11850
11851
11852
11853
11854
11855
11856
11857
11858
11859
11860
11861
11862
11863
11864
11865
11866
11867
11868
11869
11870
11871
11872
11873
11874
11875
11876
11877
11878
11879
11880
11881
11882
11883
11884
11885
11886
11887
11888
11889
11890
11891
# File 'ext/quickfix/QuickfixRuby.cpp', line 11848

SWIGINTERN VALUE _wrap_new_CharField(int nargs, VALUE *args, VALUE self) {
  int argc;
  VALUE argv[2];
  int ii;
  
  argc = nargs;
  if (argc > 2) SWIG_fail;
  for (ii = 0; (ii < argc); ++ii) {
    argv[ii] = args[ii];
  }
  if (argc == 1) {
    int _v;
    {
      int res = SWIG_AsVal_int(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      return _wrap_new_CharField__SWIG_1(nargs, args, self);
    }
  }
  if (argc == 2) {
    int _v;
    {
      int res = SWIG_AsVal_int(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      {
        int res = SWIG_AsVal_char(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_CharField__SWIG_0(nargs, args, self);
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 2, "CharField.new", 
    "    CharField.new(int field, char data)\n"
    "    CharField.new(int field)\n");
  
  return Qnil;
}

Instance Method Details

#getValue(*args) ⇒ Object



11923
11924
11925
11926
11927
11928
11929
11930
11931
11932
11933
11934
11935
11936
11937
11938
11939
11940
11941
11942
11943
11944
11945
11946
11947
11948
11949
11950
# File 'ext/quickfix/QuickfixRuby.cpp', line 11923

SWIGINTERN VALUE
_wrap_CharField_getValue(int argc, VALUE *argv, VALUE self) {
  FIX::CharField *arg1 = (FIX::CharField *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char 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_FIX__CharField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::CharField const *","getValue", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::CharField * >(argp1);
  try {
    result = (char)((FIX::CharField const *)arg1)->getValue();
  }
  catch(FIX::IncorrectDataFormat &_e) {
    rb_exc_raise(SWIG_Ruby_ExceptionType(SWIGTYPE_p_FIX__IncorrectDataFormat, SWIG_NewPointerObj((new FIX::IncorrectDataFormat(static_cast< const FIX::IncorrectDataFormat& >(_e))),SWIGTYPE_p_FIX__IncorrectDataFormat,SWIG_POINTER_OWN))); SWIG_fail;
  }
  
  vresult = SWIG_From_char(static_cast< char >(result));
  return vresult;
fail:
  return Qnil;
}

#setValue(*args) ⇒ Object



11894
11895
11896
11897
11898
11899
11900
11901
11902
11903
11904
11905
11906
11907
11908
11909
11910
11911
11912
11913
11914
11915
11916
11917
11918
11919
11920
# File 'ext/quickfix/QuickfixRuby.cpp', line 11894

SWIGINTERN VALUE
_wrap_CharField_setValue(int argc, VALUE *argv, VALUE self) {
  FIX::CharField *arg1 = (FIX::CharField *) 0 ;
  char arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char 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_FIX__CharField, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::CharField *","setValue", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::CharField * >(argp1);
  ecode2 = SWIG_AsVal_char(argv[0], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "char","setValue", 2, argv[0] ));
  } 
  arg2 = static_cast< char >(val2);
  (arg1)->setValue(arg2);
  return Qnil;
fail:
  return Qnil;
}