Class: DOF::Responses::IndicatorResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/DOF/responses/indicator_response.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ IndicatorResponse

Returns a new instance of IndicatorResponse.



12
13
14
15
16
17
# File 'lib/DOF/responses/indicator_response.rb', line 12

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

Instance Attribute Details

#dateObject (readonly)

Returns the value of attribute date.



9
10
11
# File 'lib/DOF/responses/indicator_response.rb', line 9

def date
  @date
end

#indicador_codeObject (readonly)

Returns the value of attribute indicador_code.



7
8
9
# File 'lib/DOF/responses/indicator_response.rb', line 7

def indicador_code
  @indicador_code
end

#indicador_type_codeObject (readonly)

Returns the value of attribute indicador_type_code.



8
9
10
# File 'lib/DOF/responses/indicator_response.rb', line 8

def indicador_type_code
  @indicador_type_code
end

#valueObject (readonly)

Returns the value of attribute value.



10
11
12
# File 'lib/DOF/responses/indicator_response.rb', line 10

def value
  @value
end