Class: Spreedly::ReceiverClass
- Inherits:
-
Object
- Object
- Spreedly::ReceiverClass
- Includes:
- Fields
- Defined in:
- lib/spreedly/receiver_class.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(xml_doc) ⇒ ReceiverClass
constructor
A new instance of ReceiverClass.
Methods included from Fields
#field_hash, included, #initialize_fields
Constructor Details
#initialize(xml_doc) ⇒ ReceiverClass
Returns a new instance of ReceiverClass.
8 9 10 |
# File 'lib/spreedly/receiver_class.rb', line 8 def initialize(xml_doc) initialize_fields(xml_doc) end |
Class Method Details
.new_list_from(xml_doc) ⇒ Object
12 13 14 15 16 17 |
# File 'lib/spreedly/receiver_class.rb', line 12 def self.new_list_from(xml_doc) receivers = xml_doc.xpath('.//receivers/receiver') receivers.map do |each| self.new(each) end end |