Class: SavedsearchParameter
- Inherits:
-
Object
- Object
- SavedsearchParameter
- Defined in:
- lib/refworks/savedsearch/savedsearch_parameter.rb
Instance Attribute Summary collapse
-
#components ⇒ Object
readonly
Returns the value of attribute components.
Instance Method Summary collapse
-
#initialize(rawparam) ⇒ SavedsearchParameter
constructor
A new instance of SavedsearchParameter.
Constructor Details
#initialize(rawparam) ⇒ SavedsearchParameter
Returns a new instance of SavedsearchParameter.
4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/refworks/savedsearch/savedsearch_parameter.rb', line 4 def initialize(rawparam) comps = rawparam["Parameter"] @components = Array.new if comps.class == Array comps.each do |comp| @components << SavedsearchParameterComponent.new(comp) end else @components << SavedsearchParameterComponent.new(comps) end end |
Instance Attribute Details
#components ⇒ Object (readonly)
Returns the value of attribute components.
2 3 4 |
# File 'lib/refworks/savedsearch/savedsearch_parameter.rb', line 2 def components @components end |