From bf7615c4b60f4afb12dee630c1976b74e1135fac Mon Sep 17 00:00:00 2001 From: Cody Cutrer Date: Mon, 9 Jan 2023 09:52:26 -0700 Subject: [PATCH] add implicit conversion to raw object when using Proxy as params to java methods --- lib/openhab/core/proxy.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/openhab/core/proxy.rb b/lib/openhab/core/proxy.rb index bd8b796a7..ecd6a5452 100644 --- a/lib/openhab/core/proxy.rb +++ b/lib/openhab/core/proxy.rb @@ -120,6 +120,11 @@ def self.included(klass) # define a sub-class of EventSubscriber as a child class of the including class klass.const_set(:EventSubscriber, Class.new(EventSubscriber)) end + + # @!visibility private + def to_java + __getobj__ + end end end end