# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.AirQuality.V1.Model.Pollutant do
  @moduledoc """
  Data regarding an air quality pollutant.

  ## Attributes

  *   `additionalInfo` (*type:* `GoogleApi.AirQuality.V1.Model.AdditionalInfo.t`, *default:* `nil`) - Additional information about the pollutant.
  *   `code` (*type:* `String.t`, *default:* `nil`) - The pollutant's code name (for example, "so2"). For a list of supported pollutant codes, see [Reported pollutants](/maps/documentation/air-quality/pollutants#reported_pollutants).
  *   `concentration` (*type:* `GoogleApi.AirQuality.V1.Model.Concentration.t`, *default:* `nil`) - The pollutant's concentration level measured by one of the standard air pollutation measure units.
  *   `displayName` (*type:* `String.t`, *default:* `nil`) - The pollutant's display name. For example: "NOx".
  *   `fullName` (*type:* `String.t`, *default:* `nil`) - The pollutant's full name. For chemical compounds, this is the IUPAC name. Example: "Sulfur Dioxide". For more information about the IUPAC names table, see https://iupac.org/what-we-do/periodic-table-of-elements/.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :additionalInfo => GoogleApi.AirQuality.V1.Model.AdditionalInfo.t() | nil,
          :code => String.t() | nil,
          :concentration => GoogleApi.AirQuality.V1.Model.Concentration.t() | nil,
          :displayName => String.t() | nil,
          :fullName => String.t() | nil
        }

  field(:additionalInfo, as: GoogleApi.AirQuality.V1.Model.AdditionalInfo)
  field(:code)
  field(:concentration, as: GoogleApi.AirQuality.V1.Model.Concentration)
  field(:displayName)
  field(:fullName)
end

defimpl Poison.Decoder, for: GoogleApi.AirQuality.V1.Model.Pollutant do
  def decode(value, options) do
    GoogleApi.AirQuality.V1.Model.Pollutant.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.AirQuality.V1.Model.Pollutant do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
