Class: ChinaAqi::DynamicBase
Overview
APIs with some parameters
Instance Attribute Summary collapse
-
#city ⇒ Object
Returns the value of attribute city.
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(city, querys = { avg: true, stations: :yes }) ⇒ DynamicBase
constructor
A new instance of DynamicBase.
Methods inherited from Base
Methods included from Utility
Constructor Details
#initialize(city, querys = { avg: true, stations: :yes }) ⇒ DynamicBase
Returns a new instance of DynamicBase.
67 68 69 70 71 |
# File 'lib/china_aqi/base.rb', line 67 def initialize(city, querys={ avg: true, stations: :yes }) super @city = city @parmas = querys.merge(city: city, token: ChinaAqi.token) end |
Instance Attribute Details
#city ⇒ Object
Returns the value of attribute city.
65 66 67 |
# File 'lib/china_aqi/base.rb', line 65 def city @city end |