Module: Apiway::Controller::InstanceMethods
- Defined in:
- lib/apiway/controller.rb
Instance Method Summary collapse
Instance Method Details
#initialize(action_name, client, params = {}) ⇒ Object
63 64 65 66 67 68 |
# File 'lib/apiway/controller.rb', line 63 def initialize( action_name, client, params = {} ) @action_name = action_name @action = self.class.action @action_name @client = client @params = params end |
#run ⇒ Object
70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/apiway/controller.rb', line 70 def run begin run_filters :before result = run_action run_filters :after rescue ControllerError => e failure e.params else success result end end |