Sha256: 53ee7cb3e3a101bfc1ab5e41065822f81d564b32eb16a0821c5207e1cfad893f
Contents?: true
Size: 1.46 KB
Versions: 1
Compression:
Stored size: 1.46 KB
Contents
module MoneyS3 module Parsers class CenovaHladinaType include ParserCore::BaseParser include Groups::DefiniceCeny def zkrat at 'Zkrat' end def zkrat_attributes attributes_at 'Zkrat' end def nazev at 'Nazev' end def nazev_attributes attributes_at 'Nazev' end def pozn at 'Pozn' end def pozn_attributes attributes_at 'Pozn' end def mena submodel_at(MenaType, 'Mena') end def skup at 'Skup' end def skup_attributes attributes_at 'Skup' end def ceny at 'Ceny' end def ceny_attributes attributes_at 'Ceny' end def to_h hash = {} hash[:attributes] = attributes hash[:zkrat] = zkrat if has? 'Zkrat' hash[:zkrat_attributes] = zkrat_attributes if has? 'Zkrat' hash[:nazev] = nazev if has? 'Nazev' hash[:nazev_attributes] = nazev_attributes if has? 'Nazev' hash[:pozn] = pozn if has? 'Pozn' hash[:pozn_attributes] = pozn_attributes if has? 'Pozn' hash[:mena] = mena.to_h if has? 'Mena' hash[:skup] = skup if has? 'Skup' hash[:skup_attributes] = skup_attributes if has? 'Skup' hash[:ceny] = ceny if has? 'Ceny' hash[:ceny_attributes] = ceny_attributes if has? 'Ceny' mega.inject(hash) { |memo, r| memo.merge r } end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
money_s3-1.0.0 | lib/money_s3/parsers/cenova_hladina_type.rb |