Sha256: e3ed6df981f172a0c65b3c63b41ba6c2313fd96448eb8e474094ee76413957af

Contents?: true

Size: 1 KB

Versions: 1

Compression:

Stored size: 1 KB

Contents

require 'money_s3/parsers/base_parser'

module MoneyS3
  module Parsers
    class KurzType
      include BaseParser

      def banka
        at :Banka
      end

      def datum
        at :Datum
      end

      def kod
        at :Kod
      end

      def zeme
        at :Zeme
      end

      def mnozstvi
        at :Mnozstvi
      end

      def nb_stred
        at :NBStred
      end

      def devizy_nakup
        at :DevizyNakup
      end

      def devizy_prodej
        at :DevizyProdej
      end

      def valuty_nakup
        at :ValutyNakup
      end

      def valuty_prodej
        at :ValutyProdej
      end

      def to_h
        { banka: banka,
          datum: datum,
          kod: kod,
          zeme: zeme,
          mnozstvi: mnozstvi,
          nb_stred: nb_stred,
          devizy_nakup: devizy_nakup,
          devizy_prodej: devizy_prodej,
          valuty_nakup: valuty_nakup,
          valuty_prodej: valuty_prodej
        }.delete_if { |k, v| v.nil? || v.empty? }
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
money_s3-0.4.0 lib/money_s3/parsers/kurz_type.rb