Class Hash
In: lib/em-http/core_ext/hash.rb
Parent: Object

Methods

Public Class methods

Builds a hash from an array with keys as array indices.

Public Instance methods

Stolen partially from Merb : noobkit.com/show/ruby/gems/development/merb/hash/to_params.html Convert this hash to a query string:

  { :name => "Bob",
    :address => {
      :street => '111 Ruby Ave.',
      :city => 'Ruby Central',
      :phones => ['111-111-1111', '222-222-2222']
    }
  }.to_params
  #=> "name=Bob&address[city]=Ruby Central&address[phones]=111-111-1111222-222-2222&address[street]=111 Ruby Ave."

[Validate]