Sha256: d81d07dc612d7dcee0f7528c1d535293ef3d8bf829116ae41be3d04b313c0a8c

Contents?: true

Size: 644 Bytes

Versions: 24

Compression:

Stored size: 644 Bytes

Contents

module Internals

  module Adapters
  
    #
    #
    module Rack
    
      class LiveParameters < Base

        def initialize live_parameters
          @live_parameters = live_parameters
        end
      
        #
        #
        def to_app options = {}
          # For capturing by the lambda block.
          #
          live_parameters = @live_parameters
        
          lambda do |env|
            params = ::Rack::Request.new(env).params
          
            results = live_parameters.parameters params
          
            respond_with results.to_json
          end
        end
      
      end
    
    end
  
  end
  
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
picky-2.5.2 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.5.1 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.5.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.4.3 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.4.2 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.4.1 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.4.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.3.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.2.1 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.2.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.1.2 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.1.1 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.1.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.0.0 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.0.0.pre3 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.0.0.pre2 lib/picky/internals/adapters/rack/live_parameters.rb
picky-2.0.0.pre1 lib/picky/internals/adapters/rack/live_parameters.rb
picky-1.5.4 lib/picky/internals/adapters/rack/live_parameters.rb
picky-1.5.3 lib/picky/internals/adapters/rack/live_parameters.rb
picky-1.5.2 lib/picky/internals/adapters/rack/live_parameters.rb