Class: Google::Apis::AirqualityV1::HourInfo

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/airquality_v1/classes.rb,
lib/google/apis/airquality_v1/representations.rb,
lib/google/apis/airquality_v1/representations.rb

Overview

Contains the air quality information for each hour in the requested range. For example, if the request is for 48 hours of history there will be 48 elements of hourly info.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ HourInfo

Returns a new instance of HourInfo.



394
395
396
# File 'lib/google/apis/airquality_v1/classes.rb', line 394

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#date_timeString

A rounded down timestamp indicating the time the data refers to in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. For example: "2014-10-02T15:00:00Z". Corresponds to the JSON property dateTime

Returns:

  • (String)


370
371
372
# File 'lib/google/apis/airquality_v1/classes.rb', line 370

def date_time
  @date_time
end

#health_recommendationsGoogle::Apis::AirqualityV1::HealthRecommendations

Health recommendations for different population groups in a free text format. The recommendations are derived from their associated air quality conditions. Corresponds to the JSON property healthRecommendations



376
377
378
# File 'lib/google/apis/airquality_v1/classes.rb', line 376

def health_recommendations
  @health_recommendations
end

#indexesArray<Google::Apis::AirqualityV1::AirQualityIndex>

Based on the request parameters, this list will include (up to) two air quality indexes: - Universal AQI. Will be returned if the universalAqi boolean is set to true. - Local AQI. Will be returned if the LOCAL_AQI extra computation is specified. Corresponds to the JSON property indexes



384
385
386
# File 'lib/google/apis/airquality_v1/classes.rb', line 384

def indexes
  @indexes
end

#pollutantsArray<Google::Apis::AirqualityV1::Pollutant>

A list of pollutants affecting the location specified in the request. Note: This field will be returned only for requests that specified one or more of the following extra computations: POLLUTANT_ADDITIONAL_INFO, DOMINANT_POLLUTANT_CONCENTRATION, POLLUTANT_CONCENTRATION. Corresponds to the JSON property pollutants



392
393
394
# File 'lib/google/apis/airquality_v1/classes.rb', line 392

def pollutants
  @pollutants
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



399
400
401
402
403
404
# File 'lib/google/apis/airquality_v1/classes.rb', line 399

def update!(**args)
  @date_time = args[:date_time] if args.key?(:date_time)
  @health_recommendations = args[:health_recommendations] if args.key?(:health_recommendations)
  @indexes = args[:indexes] if args.key?(:indexes)
  @pollutants = args[:pollutants] if args.key?(:pollutants)
end