Sha256: 9769c11194180381e134fa1ec03cd6933b3364a374ea28ad75cbfee968e004e3

Contents?: true

Size: 482 Bytes

Versions: 21

Compression:

Stored size: 482 Bytes

Contents

module Appfuel
  module Application
    module Dispatcher

      def dispatch(request, container)
        begin
          container[:feature_initializer].call(request.feature, container)
          action   = container[:action_loader].call(request.namespace, container)
          response = action.run(request.inputs)
        rescue => e
          handler = Appfuel::ResponseHandler.new
          response = handler.error(e)
        end

        response
      end
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
appfuel-0.5.8 lib/appfuel/application/dispatcher.rb
appfuel-0.5.7 lib/appfuel/application/dispatcher.rb
appfuel-0.5.6 lib/appfuel/application/dispatcher.rb
appfuel-0.5.5 lib/appfuel/application/dispatcher.rb
appfuel-0.5.4 lib/appfuel/application/dispatcher.rb
appfuel-0.5.3 lib/appfuel/application/dispatcher.rb
appfuel-0.5.2 lib/appfuel/application/dispatcher.rb
appfuel-0.5.1 lib/appfuel/application/dispatcher.rb
appfuel-0.5.0 lib/appfuel/application/dispatcher.rb
appfuel-0.4.5 lib/appfuel/application/dispatcher.rb
appfuel-0.4.4 lib/appfuel/application/dispatcher.rb
appfuel-0.4.3 lib/appfuel/application/dispatcher.rb
appfuel-0.4.2 lib/appfuel/application/dispatcher.rb
appfuel-0.4.1 lib/appfuel/application/dispatcher.rb
appfuel-0.4.0 lib/appfuel/application/dispatcher.rb
appfuel-0.3.4 lib/appfuel/application/dispatcher.rb
appfuel-0.3.3 lib/appfuel/application/dispatcher.rb
appfuel-0.3.2 lib/appfuel/application/dispatcher.rb
appfuel-0.3.1 lib/appfuel/application/dispatcher.rb
appfuel-0.3.0 lib/appfuel/application/dispatcher.rb