Module: Futuristic
- Defined in:
- lib/futuristic/futuristic.rb,
lib/futuristic/version.rb
Overview
Futuristic
Constant Summary collapse
- VERSION =
"0.4.3"
Instance Method Summary collapse
Instance Method Details
#future ⇒ Object
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/futuristic/futuristic.rb', line 3 def future proxy = Class.new(BasicObject) do def initialize(obj) @object = obj end def method_missing(meth, *args, &blk) Dispatch::Future.new { @object.send(meth, *args, &blk) } end def respond_to_missing?(meth, include_private = false) @object.respond_to?(meth) || super end end proxy.new(self) end |