Sha256: 7713c8ed8fbc4375531dc15929ffa13fb35c9c6e22795a5b6d47d1c28ca5fad2
Contents?: true
Size: 368 Bytes
Versions: 3
Compression:
Stored size: 368 Bytes
Contents
class RubyExt::CallbacksProxy < BasicObject attr_reader :object def initialize object, callback_name @object, @callback_name = object, callback_name end def callback_proxy? true end protected def method_missing m, *args, &block object.run_callbacks @callback_name, m do object.public_send m, *args, &block end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
ruby_ext-4.0.2 | lib/ruby_ext/more/callbacks_proxy.rb |
ruby_ext-4.0.1 | lib/ruby_ext/more/callbacks_proxy.rb |
ruby_ext-4.0.0 | lib/ruby_ext/more/callbacks_proxy.rb |