Sha256: e5ab05846500879fec202d61aea62f97117ef326e989960da3b94a3b2e79f985

Contents?: true

Size: 635 Bytes

Versions: 7

Compression:

Stored size: 635 Bytes

Contents

module MoneyS3
  module Parsers
    class Control
      include ParserCore::BaseParser

      def cislo_davky
        submodel_at(MessageRootType, 'CisloDavky')
      end

      def kod_agendy
        submodel_at(MessageRootType, 'KodAgendy')
      end

      def hosp_rok
        submodel_at(MessageRootType, 'HospRok')
      end

      def to_h
        hash = {}
        hash[:attributes] = attributes

        hash[:cislo_davky] = cislo_davky.to_h if has? 'CisloDavky'
        hash[:kod_agendy] = kod_agendy.to_h if has? 'KodAgendy'
        hash[:hosp_rok] = hosp_rok.to_h if has? 'HospRok'

        hash
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
money_s3-2.4.1 lib/money_s3/parsers/control.rb
money_s3-2.4.0 lib/money_s3/parsers/control.rb
money_s3-2.3.0 lib/money_s3/parsers/control.rb
money_s3-2.2.0 lib/money_s3/parsers/control.rb
money_s3-2.1.0 lib/money_s3/parsers/control.rb
money_s3-2.0.0 lib/money_s3/parsers/control.rb
money_s3-1.0.0 lib/money_s3/parsers/control.rb