diff options
author | Jose <jose@zeroc.com> | 2019-06-21 21:10:51 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2019-06-21 21:11:22 +0200 |
commit | 004138a45e1dc99c7a3ed61d6ee000b6638ae325 (patch) | |
tree | bfb9d6c9ae5f79b4fcf9ea7726bed0290497c473 /ruby | |
parent | Fixed incorrect comment for ice_flushBatchRequestsAsync. Fixes #379. (diff) | |
download | ice-004138a45e1dc99c7a3ed61d6ee000b6638ae325.tar.bz2 ice-004138a45e1dc99c7a3ed61d6ee000b6638ae325.tar.xz ice-004138a45e1dc99c7a3ed61d6ee000b6638ae325.zip |
Add ice_isFixed - Close #356
Diffstat (limited to 'ruby')
-rw-r--r-- | ruby/src/IceRuby/Proxy.cpp | 14 | ||||
-rw-r--r-- | ruby/test/Ice/proxy/AllTests.rb | 2 |
2 files changed, 16 insertions, 0 deletions
diff --git a/ruby/src/IceRuby/Proxy.cpp b/ruby/src/IceRuby/Proxy.cpp index d5b1c175baa..c06588261fe 100644 --- a/ruby/src/IceRuby/Proxy.cpp +++ b/ruby/src/IceRuby/Proxy.cpp @@ -921,6 +921,19 @@ IceRuby_ObjectPrx_ice_fixed(VALUE self, VALUE con) extern "C" VALUE +IceRuby_ObjectPrx_ice_isFixed(VALUE self) +{ + ICE_RUBY_TRY + { + Ice::ObjectPrx p = getProxy(self); + return p->ice_isFixed() ? Qtrue : Qfalse; + } + ICE_RUBY_CATCH + return Qnil; +} + +extern "C" +VALUE IceRuby_ObjectPrx_ice_getConnection(VALUE self) { ICE_RUBY_TRY @@ -1329,6 +1342,7 @@ IceRuby::initProxy(VALUE iceModule) rb_define_method(_proxyClass, "ice_getTimeout", CAST_METHOD(IceRuby_ObjectPrx_ice_getTimeout), 0); rb_define_method(_proxyClass, "ice_connectionId", CAST_METHOD(IceRuby_ObjectPrx_ice_connectionId), 1); rb_define_method(_proxyClass, "ice_fixed", CAST_METHOD(IceRuby_ObjectPrx_ice_fixed), 1); + rb_define_method(_proxyClass, "ice_isFixed", CAST_METHOD(IceRuby_ObjectPrx_ice_isFixed), 0); rb_define_method(_proxyClass, "ice_getConnection", CAST_METHOD(IceRuby_ObjectPrx_ice_getConnection), 0); rb_define_method(_proxyClass, "ice_getCachedConnection", CAST_METHOD(IceRuby_ObjectPrx_ice_getCachedConnection), 0); rb_define_method(_proxyClass, "ice_flushBatchRequests", CAST_METHOD(IceRuby_ObjectPrx_ice_flushBatchRequests), 0); diff --git a/ruby/test/Ice/proxy/AllTests.rb b/ruby/test/Ice/proxy/AllTests.rb index cde9fef06b8..3a923e4d0d1 100644 --- a/ruby/test/Ice/proxy/AllTests.rb +++ b/ruby/test/Ice/proxy/AllTests.rb @@ -651,6 +651,8 @@ def allTests(helper, communicator) STDOUT.flush connection = cl.ice_getConnection() if connection != nil + test(!cl.ice_isFixed()) + test(cl.ice_fixed(connection).ice_isFixed()) cl.ice_fixed(connection).getContext() test(cl.ice_secure(true).ice_fixed(connection).ice_isSecure()) test(cl.ice_facet("facet").ice_fixed(connection).ice_getFacet() == "facet") |