Module: Proxen

Defined in:
lib/proxen.rb

Defined Under Namespace

Classes: Proxy

Instance Method Summary collapse

Instance Method Details

#proxy_to(*targets) ⇒ Object



97
98
99
100
101
102
103
104
105
# File 'lib/proxen.rb', line 97

def proxy_to(*targets)
  Proxen::Proxy.add(self, *targets)

  class_eval(<<-END, __FILE__, __LINE__)
    def method_missing(sym, *args, &block)
      Proxen::Proxy.handle(self, sym, *args, &block) || super
    end
  END
end