Sha256: 24a5fa22ee5b929460750f27e637b09099799e7549ec6806dfd37dd5e2f354b2

Contents?: true

Size: 601 Bytes

Versions: 1

Compression:

Stored size: 601 Bytes

Contents

require 'money_s3/parsers/base_parser'
require 'money_s3/parsers/nep_platidlo_type'

module MoneyS3
  module Parsers
    class NepPlatbaType
      include BaseParser

      def mnozstvi_mj
        at :MnozstviMJ
      end

      def castka
        at :Castka
      end

      def platidlo
        submodel_at(NepPlatidloType, :Platidlo)
      end

      def to_h
        hash = {}

        hash[:mnozstvi_mj] = mnozstvi_mj if raw.key? :MnozstviMJ
        hash[:castka] = castka if raw.key? :Castka
        hash[:platidlo] = platidlo.to_h if raw.key? :Platidlo

        hash
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
money_s3-0.5.0 lib/money_s3/parsers/nep_platba_type.rb