Sha256: c77f5e90dbb4692a2637a7e46ed9386fc058f4174de97c7d9e7b5c99d130be71

Contents?: true

Size: 1.11 KB

Versions: 6

Compression:

Stored size: 1.11 KB

Contents

module MoneyS3
  module Builders
    class EkategorieType
      include ParserCore::BaseBuilder

      def builder
        root = Ox::Element.new(name)
        root = add_attributes_and_namespaces(root)

        root << build_element('ID', data[:id], data[:id_attributes]) if data.key? :id
        root << build_element('Name', data[:name], data[:name_attributes]) if data.key? :name
        root << build_element('Descript', data[:descript], data[:descript_attributes]) if data.key? :descript
        root << build_element('IN_Changed', data[:in_changed], data[:in_changed_attributes]) if data.key? :in_changed
        root << build_element('NoPublic', data[:no_public], data[:no_public_attributes]) if data.key? :no_public
        if data.key? :e_shop_info
          root << EShopInfo.new('eShopInfo', data[:e_shop_info]).builder
        end
        if data.key? :seznam_podr_kategorii
          element = Ox::Element.new('SeznamPodrKategorii')
          data[:seznam_podr_kategorii].each { |i| element << EkategorieType.new('eKategorie', i).builder }
          root << element
        end

        root
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
money_s3-2.4.1 lib/money_s3/builders/ekategorie_type.rb
money_s3-2.4.0 lib/money_s3/builders/ekategorie_type.rb
money_s3-2.3.0 lib/money_s3/builders/ekategorie_type.rb
money_s3-2.2.0 lib/money_s3/builders/ekategorie_type.rb
money_s3-2.1.0 lib/money_s3/builders/ekategorie_type.rb
money_s3-2.0.0 lib/money_s3/builders/ekategorie_type.rb