java_import Java::javafx.beans.binding.StringBinding
class RubyStringBinding < StringBinding
def initialize(property:, method:)
super()
@property, @method = property, method
bind @property
end
def computeValue
property_value = @property.get
return unless property_value
property_value.__send__ @method
end
end
The Java bindings provided from Bindings assumes Java reflective lookup so they cannot see our Ruby methods...
The Java bindings provided from Bindings assumes Java reflective lookup so they cannot see our Ruby methods...