Sha256: 587b366256adc515582d3fda4e9c13b43c88f23b3598f0572e54ee041bab2217

Contents?: true

Size: 488 Bytes

Versions: 5

Compression:

Stored size: 488 Bytes

Contents

require 'money_s3/builders/base_builder'
require 'money_s3/builders/cinnost'

module MoneyS3
  module Builders
    class SeznamCinnosti
      include BaseBuilder

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

        if data.key? :cinnost
          data[:cinnost].each { |i| root << Cinnost.new('Cinnost', i).builder }
        end

        root
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
money_s3-0.10.0 lib/money_s3/builders/seznam_cinnosti.rb
money_s3-0.9.0 lib/money_s3/builders/seznam_cinnosti.rb
money_s3-0.8.0 lib/money_s3/builders/seznam_cinnosti.rb
money_s3-0.7.0 lib/money_s3/builders/seznam_cinnosti.rb
money_s3-0.6.0 lib/money_s3/builders/seznam_cinnosti.rb