Class: FakeChargify::ProductFamily

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#accounting_codeObject

Returns the value of attribute accounting_code.



5
6
7
# File 'lib/fake_chargify/product_family.rb', line 5

def accounting_code
  @accounting_code
end

#handleObject

Returns the value of attribute handle.



5
6
7
# File 'lib/fake_chargify/product_family.rb', line 5

def handle
  @handle
end

#nameObject

Returns the value of attribute name.



5
6
7
# File 'lib/fake_chargify/product_family.rb', line 5

def name
  @name
end

Instance Method Details

#to_xmlObject



7
8
9
10
11
12
13
14
15
16
# File 'lib/fake_chargify/product_family.rb', line 7

def to_xml
  builder = Nokogiri::XML::Builder.new do |xml|
    xml.product_family {
      xml.accounting_code accounting_code
      xml.handle handle
      xml.name name
    }
  end
  builder.to_xml
end