Sha256: 74c13483f0c315e78e335d3489d71da0ae0fcf94d5218ffc2db842403fb4c808

Contents?: true

Size: 634 Bytes

Versions: 1

Compression:

Stored size: 634 Bytes

Contents

module MoneyS3
  module Builders
    class EShopInfo
      include ParserCore::BaseBuilder

      def builder
        root = Ox::Element.new(name)
        if data.key? :attributes
          data[:attributes].each { |k, v| root[k] = v }
        end

        root << build_element('eShopID', data[:e_shop_id], data[:e_shop_id_attributes]) if data.key? :e_shop_id
        root << build_element('eShopName', data[:e_shop_name], data[:e_shop_name_attributes]) if data.key? :e_shop_name
        root << build_element('eSaleID', data[:e_sale_id], data[:e_sale_id_attributes]) if data.key? :e_sale_id

        root
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
money_s3-1.0.0 lib/money_s3/builders/e_shop_info.rb