Class: Parameters

Inherits:
Object
  • Object
show all
Includes:
Enumerable
Defined in:
lib/named_parameter/parameters.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(parameters_array) ⇒ Parameters

Returns a new instance of Parameters.



6
7
8
9
10
# File 'lib/named_parameter/parameters.rb', line 6

def initialize(parameters_array)
  @entries = parameters_array.collect do |parameter_array| 
    Parameter.new parameter_array
  end
end

Instance Attribute Details

#entriesObject (readonly)

Returns the value of attribute entries.



4
5
6
# File 'lib/named_parameter/parameters.rb', line 4

def entries
  @entries
end

Instance Method Details

#each(&block) ⇒ Object



12
13
14
# File 'lib/named_parameter/parameters.rb', line 12

def each(&block)
  @entries.each(&block)
end