Class: OpalKelly::OkCScriptValue

Inherits:
Object
  • Object
show all
Defined in:
ext/OpalKelly/FrontPanelDLL_wrap.cxx

Instance Method Summary collapse

Constructor Details

#initialize(*args, self) ⇒ Object



24298
24299
24300
24301
24302
24303
24304
24305
24306
24307
24308
24309
24310
24311
24312
24313
24314
24315
24316
24317
24318
24319
24320
24321
24322
24323
24324
24325
24326
24327
24328
24329
24330
24331
24332
24333
24334
24335
24336
24337
24338
24339
24340
24341
24342
24343
24344
24345
24346
24347
24348
24349
24350
24351
24352
24353
24354
24355
24356
24357
24358
24359
24360
24361
24362
24363
24364
24365
24366
24367
24368
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24298

SWIGINTERN VALUE _wrap_new_okCScriptValue(int nargs, VALUE *args, VALUE self) {
  int argc;
  VALUE argv[1];
  int ii;
  
  argc = nargs;
  if (argc > 1) SWIG_fail;
  for (ii = 0; (ii < argc); ++ii) {
    argv[ii] = args[ii];
  }
  if (argc == 0) {
    return _wrap_new_okCScriptValue__SWIG_0(nargs, args, self);
  }
  if (argc == 1) {
    int _v;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_OpalKelly__Buffer, SWIG_POINTER_NO_NULL);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_okCScriptValue__SWIG_4(nargs, args, self);
    }
  }
  if (argc == 1) {
    int _v;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_OpalKelly__ScriptValue, SWIG_POINTER_NO_NULL);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_okCScriptValue__SWIG_5(nargs, args, self);
    }
  }
  if (argc == 1) {
    int _v;
    {
      int res = SWIG_AsVal_int(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      return _wrap_new_okCScriptValue__SWIG_1(nargs, args, self);
    }
  }
  if (argc == 1) {
    int _v;
    int res = SWIG_AsCharPtrAndSize(argv[0], 0, NULL, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_okCScriptValue__SWIG_3(nargs, args, self);
    }
  }
  if (argc == 1) {
    int _v;
    {
      int res = SWIG_AsVal_bool(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      return _wrap_new_okCScriptValue__SWIG_2(nargs, args, self);
    }
  }
  
fail:
  Ruby_Format_OverloadedError( argc, 1, "ScriptValue.new", 
    "    ScriptValue.new()\n"
    "    ScriptValue.new(int n)\n"
    "    ScriptValue.new(bool b)\n"
    "    ScriptValue.new(char const *s)\n"
    "    ScriptValue.new(OpalKelly::Buffer buf)\n"
    "    ScriptValue.new(OpalKelly::ScriptValue const &value)\n");
  
  return Qnil;
}

Instance Method Details

#GetBool(*args) ⇒ Object



24451
24452
24453
24454
24455
24456
24457
24458
24459
24460
24461
24462
24463
24464
24465
24466
24467
24468
24469
24470
24471
24472
24473
24474
24475
24476
24477
24478
24479
24480
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24451

SWIGINTERN VALUE
_wrap_okCScriptValue_GetBool(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","GetBool", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  {
    /*@SWIG:/home/runner/work/frontpanel-release/frontpanel-release/frontpanel-src/FrontPanelDLL/FrontPanelDLL.i,71,okExceptionHandlingCode@*/	try {
      result = (bool)((OpalKelly::ScriptValue const *)arg1)->GetBool();
    } catch (const std::exception& e) {
      SWIG_Error(SWIG_RuntimeError, e.what());
      goto fail;
    }
    /*@SWIG@*/
  }
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#GetBuffer(*args) ⇒ Object



24563
24564
24565
24566
24567
24568
24569
24570
24571
24572
24573
24574
24575
24576
24577
24578
24579
24580
24581
24582
24583
24584
24585
24586
24587
24588
24589
24590
24591
24592
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24563

SWIGINTERN VALUE
_wrap_okCScriptValue_GetBuffer(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  OpalKelly::Buffer 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","GetBuffer", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  {
    /*@SWIG:/home/runner/work/frontpanel-release/frontpanel-release/frontpanel-src/FrontPanelDLL/FrontPanelDLL.i,71,okExceptionHandlingCode@*/	try {
      result = ((OpalKelly::ScriptValue const *)arg1)->GetBuffer();
    } catch (const std::exception& e) {
      SWIG_Error(SWIG_RuntimeError, e.what());
      goto fail;
    }
    /*@SWIG@*/
  }
  vresult = SWIG_NewPointerObj((new OpalKelly::Buffer(static_cast< const OpalKelly::Buffer& >(result))), SWIGTYPE_p_OpalKelly__Buffer, SWIG_POINTER_OWN |  0 );
  return vresult;
fail:
  return Qnil;
}

#GetNumber(*args) ⇒ Object



24395
24396
24397
24398
24399
24400
24401
24402
24403
24404
24405
24406
24407
24408
24409
24410
24411
24412
24413
24414
24415
24416
24417
24418
24419
24420
24421
24422
24423
24424
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24395

SWIGINTERN VALUE
_wrap_okCScriptValue_GetNumber(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","GetNumber", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  {
    /*@SWIG:/home/runner/work/frontpanel-release/frontpanel-release/frontpanel-src/FrontPanelDLL/FrontPanelDLL.i,71,okExceptionHandlingCode@*/	try {
      result = (int)((OpalKelly::ScriptValue const *)arg1)->GetNumber();
    } catch (const std::exception& e) {
      SWIG_Error(SWIG_RuntimeError, e.what());
      goto fail;
    }
    /*@SWIG@*/
  }
  vresult = SWIG_From_int(static_cast< int >(result));
  return vresult;
fail:
  return Qnil;
}

#GetString(*args) ⇒ Object



24507
24508
24509
24510
24511
24512
24513
24514
24515
24516
24517
24518
24519
24520
24521
24522
24523
24524
24525
24526
24527
24528
24529
24530
24531
24532
24533
24534
24535
24536
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24507

SWIGINTERN VALUE
_wrap_okCScriptValue_GetString(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::string 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","GetString", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  {
    /*@SWIG:/home/runner/work/frontpanel-release/frontpanel-release/frontpanel-src/FrontPanelDLL/FrontPanelDLL.i,71,okExceptionHandlingCode@*/	try {
      result = ((OpalKelly::ScriptValue const *)arg1)->GetString();
    } catch (const std::exception& e) {
      SWIG_Error(SWIG_RuntimeError, e.what());
      goto fail;
    }
    /*@SWIG@*/
  }
  vresult = SWIG_From_std_string(static_cast< std::string >(result));
  return vresult;
fail:
  return Qnil;
}

#IsBool(*args) ⇒ Object



24427
24428
24429
24430
24431
24432
24433
24434
24435
24436
24437
24438
24439
24440
24441
24442
24443
24444
24445
24446
24447
24448
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24427

SWIGINTERN VALUE
_wrap_okCScriptValue_IsBool(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","IsBool", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  result = (bool)((OpalKelly::ScriptValue const *)arg1)->IsBool();
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#IsBuffer(*args) ⇒ Object



24539
24540
24541
24542
24543
24544
24545
24546
24547
24548
24549
24550
24551
24552
24553
24554
24555
24556
24557
24558
24559
24560
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24539

SWIGINTERN VALUE
_wrap_okCScriptValue_IsBuffer(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","IsBuffer", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  result = (bool)((OpalKelly::ScriptValue const *)arg1)->IsBuffer();
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#IsNumber(*args) ⇒ Object



24371
24372
24373
24374
24375
24376
24377
24378
24379
24380
24381
24382
24383
24384
24385
24386
24387
24388
24389
24390
24391
24392
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24371

SWIGINTERN VALUE
_wrap_okCScriptValue_IsNumber(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","IsNumber", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  result = (bool)((OpalKelly::ScriptValue const *)arg1)->IsNumber();
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}

#IsString(*args) ⇒ Object



24483
24484
24485
24486
24487
24488
24489
24490
24491
24492
24493
24494
24495
24496
24497
24498
24499
24500
24501
24502
24503
24504
# File 'ext/OpalKelly/FrontPanelDLL_wrap.cxx', line 24483

SWIGINTERN VALUE
_wrap_okCScriptValue_IsString(int argc, VALUE *argv, VALUE self) {
  OpalKelly::ScriptValue *arg1 = (OpalKelly::ScriptValue *) 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_OpalKelly__ScriptValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "OpalKelly::ScriptValue const *","IsString", 1, self )); 
  }
  arg1 = reinterpret_cast< OpalKelly::ScriptValue * >(argp1);
  result = (bool)((OpalKelly::ScriptValue const *)arg1)->IsString();
  vresult = SWIG_From_bool(static_cast< bool >(result));
  return vresult;
fail:
  return Qnil;
}