lib/google_api/display_video/v1/model/transcode.ex

# 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.DisplayVideo.V1.Model.Transcode do
  @moduledoc """
  Represents information about the transcoded audio or video file.

  ## Attributes

  *   `audioBitRateKbps` (*type:* `String.t`, *default:* `nil`) - The bit rate for the audio stream of the transcoded video, or the bit rate for the transcoded audio, in kilobits per second.
  *   `audioSampleRateHz` (*type:* `String.t`, *default:* `nil`) - The sample rate for the audio stream of the transcoded video, or the sample rate for the transcoded audio, in hertz.
  *   `bitRateKbps` (*type:* `String.t`, *default:* `nil`) - The transcoding bit rate of the transcoded video, in kilobits per second.
  *   `dimensions` (*type:* `GoogleApi.DisplayVideo.V1.Model.Dimensions.t`, *default:* `nil`) - The dimensions of the transcoded video.
  *   `fileSizeBytes` (*type:* `String.t`, *default:* `nil`) - The size of the transcoded file, in bytes.
  *   `frameRate` (*type:* `number()`, *default:* `nil`) - The frame rate of the transcoded video, in frames per second.
  *   `mimeType` (*type:* `String.t`, *default:* `nil`) - The MIME type of the transcoded file.
  *   `name` (*type:* `String.t`, *default:* `nil`) - The name of the transcoded file.
  *   `transcoded` (*type:* `boolean()`, *default:* `nil`) - Indicates if the transcoding was successful.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :audioBitRateKbps => String.t() | nil,
          :audioSampleRateHz => String.t() | nil,
          :bitRateKbps => String.t() | nil,
          :dimensions => GoogleApi.DisplayVideo.V1.Model.Dimensions.t() | nil,
          :fileSizeBytes => String.t() | nil,
          :frameRate => number() | nil,
          :mimeType => String.t() | nil,
          :name => String.t() | nil,
          :transcoded => boolean() | nil
        }

  field(:audioBitRateKbps)
  field(:audioSampleRateHz)
  field(:bitRateKbps)
  field(:dimensions, as: GoogleApi.DisplayVideo.V1.Model.Dimensions)
  field(:fileSizeBytes)
  field(:frameRate)
  field(:mimeType)
  field(:name)
  field(:transcoded)
end

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

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