Class: ZammadAPI::Dispatcher
- Inherits:
-
Object
- Object
- ZammadAPI::Dispatcher
- Defined in:
- lib/zammad_api/dispatcher.rb
Instance Method Summary collapse
-
#initialize(transport, resource) ⇒ Dispatcher
constructor
A new instance of Dispatcher.
- #method_missing(method, *args) ⇒ Object
Constructor Details
#initialize(transport, resource) ⇒ Dispatcher
Returns a new instance of Dispatcher.
4 5 6 7 |
# File 'lib/zammad_api/dispatcher.rb', line 4 def initialize(transport, resource) @transport = transport @resource = resource end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args) ⇒ Object
9 10 11 |
# File 'lib/zammad_api/dispatcher.rb', line 9 def method_missing(method, *args) @resource.send(method, @transport, args[0]) end |