Sha256: cc12eabb32b6b84f6a27472c02cc575b5b8c4f21c85bbc73bc6726b05dc9070f

Contents?: true

Size: 438 Bytes

Versions: 1

Compression:

Stored size: 438 Bytes

Contents

require 'bigdecimal'

module DOF
  module Responses
    class IndicatorResponse

      attr_reader :indicador_code
      attr_reader :indicador_type_code
      attr_reader :date
      attr_reader :value

      def initialize(data)
        @indicador_code = data["codIndicador"]
        @indicador_type_code = data["codTipoIndicador"]
        @date = data["fecha"]
        @value = BigDecimal(data["valor"])
      end
    end    
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
dof-1.0.0 lib/DOF/responses/indicator_response.rb