Class: Quickfix::Acceptor

Inherits:
Object
  • Object
show all
Defined in:
lib/quickfix_ruby.rb,
ext/quickfix/QuickfixRuby.cpp

Instance Method Summary collapse

Instance Method Details

#block(*args) ⇒ Object



109995
109996
109997
109998
109999
110000
110001
110002
110003
110004
110005
110006
110007
110008
110009
110010
110011
110012
110013
110014
110015
110016
110017
110018
110019
110020
110021
110022
110023
110024
# File 'ext/quickfix/QuickfixRuby.cpp', line 109995

SWIGINTERN VALUE
_wrap_Acceptor_block(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  
  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__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor *","block", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      (arg1)->block();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  return Qnil;
fail:
  return Qnil;
}

#getApplication(*args) ⇒ Object



110543
110544
110545
110546
110547
110548
110549
110550
110551
110552
110553
110554
110555
110556
110557
110558
110559
110560
110561
110562
110563
110564
110565
110566
110567
110568
110569
110570
110571
110572
110573
110574
110575
110576
110577
110578
110579
110580
110581
# File 'ext/quickfix/QuickfixRuby.cpp', line 110543

SWIGINTERN VALUE
_wrap_Acceptor_getApplication(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Swig::Director *director = 0;
  FIX::Application *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_FIX__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor const *","getApplication", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (FIX::Application *) &((FIX::Acceptor const *)arg1)->getApplication();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  director = dynamic_cast<Swig::Director *>(result);
  if (director) {
    vresult = director->swig_get_self();
  } else {
    vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FIX__Application, 0 |  0 );
  }
  return vresult;
fail:
  return Qnil;
}

#getLog(*args) ⇒ Object



109922
109923
109924
109925
109926
109927
109928
109929
109930
109931
109932
109933
109934
109935
109936
109937
109938
109939
109940
109941
109942
109943
109944
109945
109946
109947
109948
109949
109950
109951
109952
109953
109954
109955
109956
109957
109958
109959
109960
# File 'ext/quickfix/QuickfixRuby.cpp', line 109922

SWIGINTERN VALUE
_wrap_Acceptor_getLog(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Swig::Director *director = 0;
  FIX::Log *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_FIX__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor *","getLog", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (FIX::Log *)(arg1)->getLog();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  director = dynamic_cast<Swig::Director *>(result);
  if (director) {
    vresult = director->swig_get_self();
  } else {
    vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FIX__Log, 0 |  0 );
  }
  return vresult;
fail:
  return Qnil;
}

#getMessageStoreFactory(*args) ⇒ Object



110584
110585
110586
110587
110588
110589
110590
110591
110592
110593
110594
110595
110596
110597
110598
110599
110600
110601
110602
110603
110604
110605
110606
110607
110608
110609
110610
110611
110612
110613
110614
110615
110616
# File 'ext/quickfix/QuickfixRuby.cpp', line 110584

SWIGINTERN VALUE
_wrap_Acceptor_getMessageStoreFactory(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  FIX::MessageStoreFactory *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_FIX__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor const *","getMessageStoreFactory", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (FIX::MessageStoreFactory *) &((FIX::Acceptor const *)arg1)->getMessageStoreFactory();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FIX__MessageStoreFactory, 0 |  0 );
  return vresult;
fail:
  return Qnil;
}

#getSession(*args, self) ⇒ Object



110363
110364
110365
110366
110367
110368
110369
110370
110371
110372
110373
110374
110375
110376
110377
110378
110379
110380
110381
110382
110383
110384
110385
110386
110387
110388
110389
110390
110391
110392
110393
110394
110395
110396
110397
110398
110399
110400
110401
110402
110403
110404
110405
110406
110407
110408
110409
110410
110411
110412
110413
# File 'ext/quickfix/QuickfixRuby.cpp', line 110363

SWIGINTERN VALUE _wrap_Acceptor_getSession(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__Acceptor, 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_Acceptor_getSession__SWIG_1(nargs, args, self);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__Acceptor, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_Responder, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_Acceptor_getSession__SWIG_0(nargs, args, self);
        }
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 4, "Acceptor.getSession", 
    "    FIX::Session Acceptor.getSession(std::string const &msg, Responder &)\n"
    "    FIX::Session * Acceptor.getSession(FIX::SessionID const &sessionID)\n");
  
  return Qnil;
}

#getSessions(*args) ⇒ Object



110282
110283
110284
110285
110286
110287
110288
110289
110290
110291
110292
110293
110294
110295
110296
110297
110298
110299
110300
110301
110302
110303
110304
110305
110306
110307
110308
110309
110310
110311
110312
110313
110314
# File 'ext/quickfix/QuickfixRuby.cpp', line 110282

SWIGINTERN VALUE
_wrap_Acceptor_getSessions(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::set< FIX::SessionID,std::less< FIX::SessionID >,std::allocator< FIX::SessionID > > *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_FIX__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor const *","getSessions", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (std::set< FIX::SessionID,std::less< FIX::SessionID >,std::allocator< FIX::SessionID > > *) &((FIX::Acceptor 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;
}

#getSessionSettings(*args) ⇒ Object



110416
110417
110418
110419
110420
110421
110422
110423
110424
110425
110426
110427
110428
110429
110430
110431
110432
110433
110434
110435
110436
110437
110438
110439
110440
110441
110442
110443
110444
110445
110446
110447
110448
110449
110450
110451
110452
110453
110454
110455
110456
110457
110458
110459
# File 'ext/quickfix/QuickfixRuby.cpp', line 110416

SWIGINTERN VALUE
_wrap_Acceptor_getSessionSettings(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  FIX::SessionID *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  FIX::Dictionary *result = 0 ;
  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__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor const *","getSessionSettings", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(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 &","getSessionSettings", 2, argv[0] )); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "FIX::SessionID const &","getSessionSettings", 2, argv[0])); 
  }
  arg2 = reinterpret_cast< FIX::SessionID * >(argp2);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (FIX::Dictionary *)((FIX::Acceptor const *)arg1)->getSessionSettings((FIX::SessionID const &)*arg2);
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FIX__Dictionary, 0 |  0 );
  return vresult;
fail:
  return Qnil;
}

#has(*args) ⇒ Object



110462
110463
110464
110465
110466
110467
110468
110469
110470
110471
110472
110473
110474
110475
110476
110477
110478
110479
110480
110481
110482
110483
110484
110485
110486
110487
110488
110489
110490
110491
110492
110493
110494
110495
110496
110497
110498
110499
110500
110501
110502
110503
110504
110505
# File 'ext/quickfix/QuickfixRuby.cpp', line 110462

SWIGINTERN VALUE
_wrap_Acceptor_has(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 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__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor const *","has", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(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::Acceptor 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;
}

#isLoggedOn(*args) ⇒ Object



110179
110180
110181
110182
110183
110184
110185
110186
110187
110188
110189
110190
110191
110192
110193
110194
110195
110196
110197
110198
110199
110200
110201
110202
110203
110204
110205
110206
110207
110208
110209
110210
110211
# File 'ext/quickfix/QuickfixRuby.cpp', line 110179

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

#isStopped(*args) ⇒ Object



110508
110509
110510
110511
110512
110513
110514
110515
110516
110517
110518
110519
110520
110521
110522
110523
110524
110525
110526
110527
110528
110529
110530
110531
110532
110533
110534
110535
110536
110537
110538
110539
110540
# File 'ext/quickfix/QuickfixRuby.cpp', line 110508

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

#poll(*args) ⇒ Object



110027
110028
110029
110030
110031
110032
110033
110034
110035
110036
110037
110038
110039
110040
110041
110042
110043
110044
110045
110046
110047
110048
110049
110050
110051
110052
110053
110054
110055
110056
110057
110058
110059
# File 'ext/quickfix/QuickfixRuby.cpp', line 110027

SWIGINTERN VALUE
_wrap_Acceptor_poll(int argc, VALUE *argv, VALUE self) {
  FIX::Acceptor *arg1 = (FIX::Acceptor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool 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__Acceptor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "FIX::Acceptor *","poll", 1, self )); 
  }
  arg1 = reinterpret_cast< FIX::Acceptor * >(argp1);
  {
    if(tryRubyException([&]() mutable 
        {
      result = (bool)(arg1)->poll();
          return self;
        fail:
          return Qnil;
        }) == Qnil) 
    {
      SWIG_fail;
    }
  }
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#start(*args) ⇒ Object



109963
109964
109965
# File 'ext/quickfix/QuickfixRuby.cpp', line 109963

def start
  Thread.new { block() }
end

#stop(*args, self) ⇒ Object



110134
110135
110136
110137
110138
110139
110140
110141
110142
110143
110144
110145
110146
110147
110148
110149
110150
110151
110152
110153
110154
110155
110156
110157
110158
110159
110160
110161
110162
110163
110164
110165
110166
110167
110168
110169
110170
110171
110172
110173
110174
110175
110176
# File 'ext/quickfix/QuickfixRuby.cpp', line 110134

SWIGINTERN VALUE _wrap_Acceptor_stop(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__Acceptor, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_Acceptor_stop__SWIG_1(nargs, args, self);
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_FIX__Acceptor, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_bool(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_Acceptor_stop__SWIG_0(nargs, args, self);
      }
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 3, "Acceptor.stop", 
    "    void Acceptor.stop(bool force)\n"
    "    void Acceptor.stop()\n");
  
  return Qnil;
}