Class: StringSet

Inherits:
Object
  • Object
show all
Defined in:
lib/string_set.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes) ⇒ StringSet

Returns a new instance of StringSet.



3
4
5
# File 'lib/string_set.rb', line 3

def initialize(attributes) 
  @product_name = attributes[:product_name] 
end

Instance Attribute Details

#product_nameObject (readonly)

Returns the value of attribute product_name.



2
3
4
# File 'lib/string_set.rb', line 2

def product_name
  @product_name
end

Class Method Details

.from_xml(xml) ⇒ Object



7
8
9
# File 'lib/string_set.rb', line 7

def self.from_xml(xml) 
  new(:product_name => xml.text)
end