Class: GPS_PVT::SylphideMath::MatrixD
- Inherits:
-
((swig_class *) SWIGTYPE_p_Matrix_FrozenT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t->clientdata)->klass
- Object
- ((swig_class *) SWIGTYPE_p_Matrix_FrozenT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t->clientdata)->klass
- GPS_PVT::SylphideMath::MatrixD
- Defined in:
- ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx,
ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx
Overview
Proxy of C++ GPS_PVT::SylphideMath::MatrixD class
Class Method Summary collapse
Instance Method Summary collapse
- #[]=(*args) ⇒ Object
- #initialize(*args, self) ⇒ Object constructor
- #map!(*args, self) ⇒ Object (also: #collect!, #map_with_index!, #collect_with_index!)
- #replace!(*args, self) ⇒ Object
- #resize!(*args) ⇒ Object
- #swap_columns!(*args) ⇒ Object
- #swap_rows!(*args) ⇒ Object
Constructor Details
#initialize(*args, self) ⇒ Object
13227 13228 13229 13230 13231 13232 13233 13234 13235 13236 13237 13238 13239 13240 13241 13242 13243 13244 13245 13246 13247 13248 13249 13250 13251 13252 13253 13254 13255 13256 13257 13258 13259 13260 13261 13262 13263 13264 13265 13266 13267 13268 13269 13270 13271 13272 13273 13274 13275 13276 13277 13278 13279 13280 13281 13282 13283 13284 13285 13286 13287 13288 13289 13290 13291 13292 13293 13294 13295 13296 13297 13298 13299 13300 13301 13302 13303 13304 13305 13306 13307 13308 13309 13310 13311 13312 13313 13314 13315 13316 13317 13318 13319 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13227
SWIGINTERN VALUE _wrap_new_MatrixD(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs;
if (argc > 3) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 1) {
int _v;
{
_v = rb_block_given_p() ? 0 : 1;
}
if (_v) {
return _wrap_new_MatrixD__SWIG_3(nargs, args, self);
}
}
if (argc == 2) {
int _v;
{
int res = SWIG_AsVal_unsigned_SS_int(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_unsigned_SS_int(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_MatrixD__SWIG_1(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
{
int res = SWIG_AsVal_unsigned_SS_int(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_unsigned_SS_int(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_MatrixD__SWIG_2(nargs, args, self);
}
}
}
}
if (argc == 3) {
int _v;
{
int res = SWIG_AsVal_unsigned_SS_int(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_unsigned_SS_int(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
_v = rb_block_given_p() ? 0 : 1;
}
if (_v) {
return _wrap_new_MatrixD__SWIG_0(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "MatrixD.new",
" MatrixD.new(unsigned int const &rows, unsigned int const &columns, void const *replacer)\n"
" MatrixD.new(unsigned int const &rows, unsigned int const &columns)\n"
" MatrixD.new(unsigned int const &rows, unsigned int const &columns, double const *serialized)\n"
" MatrixD.new(void const *replacer)\n");
return Qnil;
}
|
Class Method Details
.I(*args) ⇒ Object
13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13441
SWIGINTERN VALUE
_wrap_MatrixD_I(int argc, VALUE *argv, VALUE self) {
unsigned int *arg1 = 0 ;
unsigned int temp1 ;
unsigned int val1 ;
int ecode1 = 0 ;
SwigValueWrapper< Matrix< double,Array2D_Dense< double > > > result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_unsigned_SS_int(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "unsigned int","Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__getI", 1, argv[0] ));
}
temp1 = static_cast< unsigned int >(val1);
arg1 = &temp1;
raise_if_lt_zero_after_asval(*arg1);
result = Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__getI((unsigned int const &)*arg1);
vresult = SWIG_NewPointerObj((new Matrix< double,Array2D_Dense< double > >(static_cast< const Matrix< double,Array2D_Dense< double > >& >(result))), SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
|
.scalar(*args) ⇒ Object
13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13395
SWIGINTERN VALUE
_wrap_MatrixD_scalar(int argc, VALUE *argv, VALUE self) {
unsigned int *arg1 = 0 ;
double *arg2 = 0 ;
unsigned int temp1 ;
unsigned int val1 ;
int ecode1 = 0 ;
double temp2 ;
double val2 ;
int ecode2 = 0 ;
SwigValueWrapper< Matrix< double,Array2D_Dense< double > > > result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_unsigned_SS_int(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "unsigned int","Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__getScalar", 1, argv[0] ));
}
temp1 = static_cast< unsigned int >(val1);
arg1 = &temp1;
ecode2 = SWIG_AsVal_double(argv[1], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__getScalar", 2, argv[1] ));
}
temp2 = static_cast< double >(val2);
arg2 = &temp2;
raise_if_lt_zero_after_asval(*arg1);
result = Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__getScalar((unsigned int const &)*arg1,(double const &)*arg2);
vresult = SWIG_NewPointerObj((new Matrix< double,Array2D_Dense< double > >(static_cast< const Matrix< double,Array2D_Dense< double > >& >(result))), SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
|
Instance Method Details
#[]=(*args) ⇒ Object
13330 13331 13332 13333 13334 13335 13336 13337 13338 13339 13340 13341 13342 13343 13344 13345 13346 13347 13348 13349 13350 13351 13352 13353 13354 13355 13356 13357 13358 13359 13360 13361 13362 13363 13364 13365 13366 13367 13368 13369 13370 13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13330
SWIGINTERN VALUE
_wrap_MatrixD___setitem__(int argc, VALUE *argv, VALUE self) {
Matrix< double,Array2D_Dense< double > > *arg1 = (Matrix< double,Array2D_Dense< double > > *) 0 ;
unsigned int *arg2 = 0 ;
unsigned int *arg3 = 0 ;
double *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int temp2 ;
unsigned int val2 ;
int ecode2 = 0 ;
unsigned int temp3 ;
unsigned int val3 ;
int ecode3 = 0 ;
double temp4 ;
double val4 ;
int ecode4 = 0 ;
double *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Matrix< double,Array2D_Dense< double > > *","__setitem__", 1, self ));
}
arg1 = reinterpret_cast< Matrix< double,Array2D_Dense< double > > * >(argp1);
ecode2 = SWIG_AsVal_unsigned_SS_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "unsigned int","__setitem__", 2, argv[0] ));
}
temp2 = static_cast< unsigned int >(val2);
arg2 = &temp2;
ecode3 = SWIG_AsVal_unsigned_SS_int(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "unsigned int","__setitem__", 3, argv[1] ));
}
temp3 = static_cast< unsigned int >(val3);
arg3 = &temp3;
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "double","__setitem__", 4, argv[2] ));
}
temp4 = static_cast< double >(val4);
arg4 = &temp4;
raise_if_lt_zero_after_asval(*arg2);
raise_if_lt_zero_after_asval(*arg3);
result = (double *) &Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg____setitem__(arg1,(unsigned int const &)*arg2,(unsigned int const &)*arg3,(double const &)*arg4);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_double, 0 | 0 );
return vresult;
fail:
return Qnil;
}
|
#map!(*args, self) ⇒ Object Also known as: collect!, map_with_index!, collect_with_index!
13977 13978 13979 13980 13981 13982 13983 13984 13985 13986 13987 13988 13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13977
SWIGINTERN VALUE _wrap_MatrixD_mapN___(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;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_MatrixD_mapN_____SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
_v = (MatrixUtil::sym2each_which(argv[1]) != MatrixUtil::EACH_UNKNOWN);
}
if (_v) {
return _wrap_MatrixD_mapN_____SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "map!",
" void map!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, void (*each_func)(double const &,double *,unsigned int const &,unsigned int const &), MatrixUtil::each_which_t const each_which)\n"
" void map!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, void (*each_func)(double const &,double *,unsigned int const &,unsigned int const &))\n");
return Qnil;
}
|
#replace!(*args, self) ⇒ Object
13789 13790 13791 13792 13793 13794 13795 13796 13797 13798 13799 13800 13801 13802 13803 13804 13805 13806 13807 13808 13809 13810 13811 13812 13813 13814 13815 13816 13817 13818 13819 13820 13821 13822 13823 13824 13825 13826 13827 13828 13829 13830 13831 13832 13833 13834 13835 13836 13837 13838 13839 13840 13841 13842 13843 13844 13845 13846 13847 13848 13849 13850 13851 13852 13853 13854 13855 13856 13857 13858 13859 13860 13861 13862 13863 13864 13865 13866 13867 13868 13869 13870 13871 13872 13873 13874 13875 13876 13877 13878 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13789
SWIGINTERN VALUE _wrap_MatrixD_replaceN___(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;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_MatrixD_replaceN_____SWIG_4(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_Matrix_FrozenT_double_Array2D_DenseT_double_t_MatrixViewFilterT_MatrixViewBaseT_t_t_t, SWIG_POINTER_NO_NULL);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_MatrixD_replaceN_____SWIG_2(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_Matrix_FrozenT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, SWIG_POINTER_NO_NULL);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_MatrixD_replaceN_____SWIG_1(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_MatrixD_replaceN_____SWIG_5(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
_v = rb_block_given_p() ? 0 : 1;
}
if (_v) {
return _wrap_MatrixD_replaceN_____SWIG_3(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "replace!",
" void replace!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, Matrix_Frozen< double,Array2D_Dense< double >,MatrixViewBase< > > const &matrix)\n"
" void replace!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, Matrix_Frozen< double,Array2D_Dense< double >,MatrixViewFilter< MatrixViewBase< > > > const &matrix)\n"
" void replace!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, void const *replacer)\n"
" void replace!(Matrix< double,Array2D_Dense< double > >::self_t *self_p)\n"
" void replace!(Matrix< double,Array2D_Dense< double > >::self_t *self_p, double const *serialized)\n");
return Qnil;
}
|
#resize!(*args) ⇒ Object
14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 14039 14040 14041 14042 14043 14044 14045 14046 14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 14058 14059 14060 14061 14062 14063 14064 14065 14066 14067 14068 14069 14070 14071 14072 14073 14074 14075 14076 14077 14078 14079 14080 14081 14082 14083 14084 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 14029
SWIGINTERN VALUE
_wrap_MatrixD_resizeN___(int argc, VALUE *argv, VALUE self) {
Matrix< double,Array2D_Dense< double > > *arg1 = (Matrix< double,Array2D_Dense< double > > *) 0 ;
unsigned int *arg2 = (unsigned int *) 0 ;
unsigned int *arg3 = (unsigned int *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int temp2 ;
unsigned int temp3 ;
Matrix< double,Array2D_Dense< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Matrix< double,Array2D_Dense< double > > *","resize", 1, self ));
}
arg1 = reinterpret_cast< Matrix< double,Array2D_Dense< double > > * >(argp1);
{
if(SWIG_IsOK(SWIG_AsVal_unsigned_SS_int (argv[0], &temp2))){
raise_if_lt_zero_after_asval(temp2);
arg2 = &temp2;
}
else if(NIL_P(argv[0])){
arg2 = NULL;
}
else{
SWIG_exception(SWIG_TypeError, "unsigned int is expected");
}
}
{
if(SWIG_IsOK(SWIG_AsVal_unsigned_SS_int (argv[1], &temp3))){
raise_if_lt_zero_after_asval(temp3);
arg3 = &temp3;
}
else if(NIL_P(argv[1])){
arg3 = NULL;
}
else{
SWIG_exception(SWIG_TypeError, "unsigned int is expected");
}
}
result = (Matrix< double,Array2D_Dense< double > > *) &Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__resize(arg1,(unsigned int const *)arg2,(unsigned int const *)arg3);
vresult = self;
return vresult;
fail:
return Qnil;
}
|
#swap_columns!(*args) ⇒ Object
13537 13538 13539 13540 13541 13542 13543 13544 13545 13546 13547 13548 13549 13550 13551 13552 13553 13554 13555 13556 13557 13558 13559 13560 13561 13562 13563 13564 13565 13566 13567 13568 13569 13570 13571 13572 13573 13574 13575 13576 13577 13578 13579 13580 13581 13582 13583 13584 13585 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13537
SWIGINTERN VALUE
_wrap_MatrixD_swap_columnsN___(int argc, VALUE *argv, VALUE self) {
Matrix< double,Array2D_Dense< double > > *arg1 = (Matrix< double,Array2D_Dense< double > > *) 0 ;
Matrix< double,Array2D_Dense< double > >::self_t *arg2 = (Matrix< double,Array2D_Dense< double > >::self_t *) 0 ;
unsigned int *arg3 = 0 ;
unsigned int *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int temp3 ;
unsigned int val3 ;
int ecode3 = 0 ;
unsigned int temp4 ;
unsigned int val4 ;
int ecode4 = 0 ;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Matrix< double,Array2D_Dense< double > > *","swap_columns", 1, self ));
}
arg1 = reinterpret_cast< Matrix< double,Array2D_Dense< double > > * >(argp1);
ecode3 = SWIG_AsVal_unsigned_SS_int(argv[0], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "unsigned int","swap_columns", 3, argv[0] ));
}
temp3 = static_cast< unsigned int >(val3);
arg3 = &temp3;
ecode4 = SWIG_AsVal_unsigned_SS_int(argv[1], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","swap_columns", 4, argv[1] ));
}
temp4 = static_cast< unsigned int >(val4);
arg4 = &temp4;
raise_if_lt_zero_after_asval(*arg3);
raise_if_lt_zero_after_asval(*arg4);
try {
Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__swap_columns(arg1,arg2,(unsigned int const &)*arg3,(unsigned int const &)*arg4);
} catch(std::out_of_range &_e) {
SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
}
vresult = self;
return vresult;
fail:
return Qnil;
}
|
#swap_rows!(*args) ⇒ Object
13477 13478 13479 13480 13481 13482 13483 13484 13485 13486 13487 13488 13489 13490 13491 13492 13493 13494 13495 13496 13497 13498 13499 13500 13501 13502 13503 13504 13505 13506 13507 13508 13509 13510 13511 13512 13513 13514 13515 13516 13517 13518 13519 13520 13521 13522 13523 13524 13525 |
# File 'ext/gps_pvt/SylphideMath/SylphideMath_wrap.cxx', line 13477
SWIGINTERN VALUE
_wrap_MatrixD_swap_rowsN___(int argc, VALUE *argv, VALUE self) {
Matrix< double,Array2D_Dense< double > > *arg1 = (Matrix< double,Array2D_Dense< double > > *) 0 ;
Matrix< double,Array2D_Dense< double > >::self_t *arg2 = (Matrix< double,Array2D_Dense< double > >::self_t *) 0 ;
unsigned int *arg3 = 0 ;
unsigned int *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int temp3 ;
unsigned int val3 ;
int ecode3 = 0 ;
unsigned int temp4 ;
unsigned int val4 ;
int ecode4 = 0 ;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_MatrixT_double_Array2D_DenseT_double_t_MatrixViewBaseT_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "Matrix< double,Array2D_Dense< double > > *","swap_rows", 1, self ));
}
arg1 = reinterpret_cast< Matrix< double,Array2D_Dense< double > > * >(argp1);
ecode3 = SWIG_AsVal_unsigned_SS_int(argv[0], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "unsigned int","swap_rows", 3, argv[0] ));
}
temp3 = static_cast< unsigned int >(val3);
arg3 = &temp3;
ecode4 = SWIG_AsVal_unsigned_SS_int(argv[1], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "unsigned int","swap_rows", 4, argv[1] ));
}
temp4 = static_cast< unsigned int >(val4);
arg4 = &temp4;
raise_if_lt_zero_after_asval(*arg3);
raise_if_lt_zero_after_asval(*arg4);
try {
Matrix_Sl_double_Sc_Array2D_Dense_Sl_double_Sg__Sg__swap_rows(arg1,arg2,(unsigned int const &)*arg3,(unsigned int const &)*arg4);
} catch(std::out_of_range &_e) {
SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
}
vresult = self;
return vresult;
fail:
return Qnil;
}
|