Class: AutomationObject::Proxy::Proxy

Inherits:
Object
  • Object
show all
Defined in:
lib/automation_object/proxy/proxy.rb

Overview

CompositeBase Proxy class for getting between another

Instance Method Summary collapse

Constructor Details

#initialize(subject) ⇒ Proxy

Returns a new instance of Proxy

Parameters:

  • subject (Object)


12
13
14
# File 'lib/automation_object/proxy/proxy.rb', line 12

def initialize(subject)
  @subject = subject
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &block) ⇒ Object

Parameters:

  • method (Symbol)
  • args (Array, nil)
  • block (Proc)


19
20
21
# File 'lib/automation_object/proxy/proxy.rb', line 19

def method_missing(method, *args, &block)
  @subject.send(method, *args, &block)
end