Class: Quickfix::SessionSettings

Inherits:
Object
  • Object
show all
Defined in:
ext/quickfix/QuickfixRuby.cpp

Instance Method Summary collapse

Constructor Details

#initialize(*args, self) ⇒ Object



97254
97255
97256
97257
97258
97259
97260
97261
97262
97263
97264
97265
97266
97267
97268
97269
97270
97271
97272
97273
97274
97275
97276
97277
97278
97279
97280
97281
97282
97283
97284
97285
97286
97287
97288
97289
97290
97291
97292
97293
97294
97295
97296
97297
97298
97299
97300
97301
97302
97303
97304
97305
97306
97307
97308
97309
97310
97311
97312
97313
97314
97315
97316
97317
97318
97319
97320
97321
97322
97323
# File 'ext/quickfix/QuickfixRuby.cpp', line 97254

SWIGINTERN VALUE _wrap_new_SessionSettings(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 == 0) {
    return _wrap_new_SessionSettings__SWIG_0(nargs, args, self);
  }
  if (argc == 1) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_std__istream, SWIG_POINTER_NO_NULL);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_SessionSettings__SWIG_2(nargs, args, self);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_SessionSettings__SWIG_4(nargs, args, self);
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_std__istream, SWIG_POINTER_NO_NULL);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_bool(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_SessionSettings__SWIG_1(nargs, args, self);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_bool(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_SessionSettings__SWIG_3(nargs, args, self);
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 2, "SessionSettings.new", 
    "    SessionSettings.new()\n"
    "    SessionSettings.new(std::istream &stream, bool resolveEnvVars)\n"
    "    SessionSettings.new(std::istream &stream)\n"
    "    SessionSettings.new(std::string const &file, bool resolveEnvVars)\n"
    "    SessionSettings.new(std::string const &file)\n");
  
  return Qnil;
}

Instance Method Details

#get(*args, self) ⇒ Object



97510
97511
97512
97513
97514
97515
97516
97517
97518
97519
97520
97521
97522
97523
97524
97525
97526
97527
97528
97529
97530
97531
97532
97533
97534
97535
97536
97537
97538
97539
97540
97541
97542
97543
97544
97545
97546
97547
97548
97549
97550
97551
# File 'ext/quickfix/QuickfixRuby.cpp', line 97510

SWIGINTERN VALUE _wrap_SessionSettings_get(int nargs, VALUE *args, VALUE self) {
  int argc;
  VALUE argv[3];
  int ii;
  
  argc = nargs + 1;
  argv[0] = self;
  if (argc > 3) SWIG_fail;
  for (ii = 1; (ii < argc); ++ii) {
    argv[ii] = args[ii-1];
  }
  if (argc == 1) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__SessionSettings, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_SessionSettings_get__SWIG_1(nargs, args, self);
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__SessionSettings, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_FIX__SessionID, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_SessionSettings_get__SWIG_0(nargs, args, self);
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 3, "SessionSettings.get", 
    "    FIX::Dictionary const SessionSettings.get(FIX::SessionID const &)\n"
    "    FIX::Dictionary const & SessionSettings.get()\n");
  
  return Qnil;
}

#getSessions(*args) ⇒ Object



97694
97695
97696
97697
97698
97699
97700
97701
97702
97703
97704
97705
97706
97707
97708
97709
97710
97711
97712
97713
97714
97715
97716
97717
97718
97719
97720
97721
97722
97723
97724
97725
97726
# File 'ext/quickfix/QuickfixRuby.cpp', line 97694

SWIGINTERN VALUE
_wrap_SessionSettings_getSessions(int argc, VALUE *argv, VALUE self) {
  FIX::SessionSettings *arg1 = (FIX::SessionSettings *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::set< FIX::SessionID,std::less< FIX::SessionID >,std::allocator< FIX::SessionID > > 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__SessionSettings, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::SessionSettings const *","getSessions", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::SessionSettings * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = ((FIX::SessionSettings const *)arg1)->getSessions();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = swig::from(static_cast< std::set< FIX::SessionID,std::less< FIX::SessionID >,std::allocator< FIX::SessionID > > >(result));
  return vresult;
fail:
  return Qnil;
}

#has(*args) ⇒ Object



97326
97327
97328
97329
97330
97331
97332
97333
97334
97335
97336
97337
97338
97339
97340
97341
97342
97343
97344
97345
97346
97347
97348
97349
97350
97351
97352
97353
97354
97355
97356
97357
97358
97359
97360
97361
97362
97363
97364
97365
97366
97367
97368
97369
# File 'ext/quickfix/QuickfixRuby.cpp', line 97326

SWIGINTERN VALUE
_wrap_SessionSettings_has(int argc, VALUE *argv, VALUE self) {
  FIX::SessionSettings *arg1 = (FIX::SessionSettings *) 0 ;
  FIX::SessionID *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  bool result;
  VALUE vresult = Qnil;
  
  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__SessionSettings, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::SessionSettings const *","has", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::SessionSettings * >(argp1);
  res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_FIX__SessionID,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "FIX::SessionID const &","has", 2, argv[0] )); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "FIX::SessionID const &","has", 2, argv[0])); 
  }
  arg2 = reinterpret_cast< FIX::SessionID * >(argp2);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (bool)((FIX::SessionSettings const *)arg1)->has((FIX::SessionID const &)*arg2);
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#set(*args, self) ⇒ Object



97597
97598
97599
97600
97601
97602
97603
97604
97605
97606
97607
97608
97609
97610
97611
97612
97613
97614
97615
97616
97617
97618
97619
97620
97621
97622
97623
97624
97625
97626
97627
97628
97629
97630
97631
97632
97633
97634
97635
97636
97637
97638
97639
97640
97641
97642
97643
97644
97645
97646
97647
97648
# File 'ext/quickfix/QuickfixRuby.cpp', line 97597

SWIGINTERN VALUE _wrap_SessionSettings_set(int nargs, VALUE *args, VALUE self) {
  int argc;
  VALUE argv[4];
  int ii;
  
  argc = nargs + 1;
  argv[0] = self;
  if (argc > 4) SWIG_fail;
  for (ii = 1; (ii < argc); ++ii) {
    argv[ii] = args[ii-1];
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__SessionSettings, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_FIX__Dictionary, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_SessionSettings_set__SWIG_1(nargs, args, self);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__SessionSettings, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_FIX__SessionID, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_FIX__Dictionary, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_SessionSettings_set__SWIG_0(nargs, args, self);
        }
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 4, "SessionSettings.set", 
    "    void SessionSettings.set(FIX::SessionID const &, FIX::Dictionary)\n"
    "    void SessionSettings.set(FIX::Dictionary const &defaults)\n");
  
  return Qnil;
}

#setFromString(*args) ⇒ Object



97973
97974
97975
97976
97977
97978
97979
97980
97981
97982
97983
97984
97985
97986
97987
97988
97989
97990
97991
97992
97993
97994
97995
97996
97997
97998
97999
98000
98001
98002
98003
98004
98005
98006
98007
98008
98009
98010
98011
98012
98013
98014
98015
98016
98017
98018
98019
98020
98021
98022
98023
98024
98025
# File 'ext/quickfix/QuickfixRuby.cpp', line 97973

SWIGINTERN VALUE
_wrap_SessionSettings_setFromString(int argc, VALUE *argv, VALUE self) {
  FIX::SessionSettings *arg1 = (FIX::SessionSettings *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  VALUE vresult = Qnil;
  
  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__SessionSettings, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::SessionSettings *","setFromString", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::SessionSettings * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(argv[0], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "std::string const &","setFromString", 2, argv[0] )); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::string const &","setFromString", 2, argv[0])); 
    }
    arg2 = ptr;
  }
  {
    if(tryRubyException([&]() mutable 
        {
      FIX_SessionSettings_setFromString(arg1,(std::string const &)*arg2);
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  {
    if( std::string("std::string const &") == "std::string &" )    
    {
      rb_str_resize( argv[0], 0 );
      rb_str_append( argv[0], rb_str_new2(arg2->c_str()) );
    }
  }
  if (SWIG_IsNewObj(res2)) delete arg2;
  return vresult;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return Qnil;
}

#size(*args) ⇒ Object

call-seq:

size -> size_t

Size or Length of the SessionSettings.



97659
97660
97661
97662
97663
97664
97665
97666
97667
97668
97669
97670
97671
97672
97673
97674
97675
97676
97677
97678
97679
97680
97681
97682
97683
97684
97685
97686
97687
97688
97689
97690
97691
# File 'ext/quickfix/QuickfixRuby.cpp', line 97659

SWIGINTERN VALUE
_wrap_SessionSettings_size(int argc, VALUE *argv, VALUE self) {
  FIX::SessionSettings *arg1 = (FIX::SessionSettings *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t 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__SessionSettings, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::SessionSettings const *","size", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::SessionSettings * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = ((FIX::SessionSettings const *)arg1)->size();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = SWIG_From_size_t(static_cast< size_t >(result));
  return vresult;
fail:
  return Qnil;
}