# 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.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1CallAnnotation do
  @moduledoc """
  A piece of metadata that applies to a window of a call.

  ## Attributes

  *   `annotationEndBoundary` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary.t`, *default:* `nil`) - The boundary in the conversation where the annotation ends, inclusive.
  *   `annotationStartBoundary` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary.t`, *default:* `nil`) - The boundary in the conversation where the annotation starts, inclusive.
  *   `channelTag` (*type:* `integer()`, *default:* `nil`) - The channel of the audio where the annotation occurs. For single-channel audio, this field is not populated.
  *   `entityMentionData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1EntityMentionData.t`, *default:* `nil`) - Data specifying an entity mention.
  *   `holdData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1HoldData.t`, *default:* `nil`) - Data specifying a hold.
  *   `intentMatchData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IntentMatchData.t`, *default:* `nil`) - Data specifying an intent match.
  *   `interruptionData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1InterruptionData.t`, *default:* `nil`) - Data specifying an interruption.
  *   `issueMatchData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IssueMatchData.t`, *default:* `nil`) - Data specifying an issue match.
  *   `phraseMatchData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1PhraseMatchData.t`, *default:* `nil`) - Data specifying a phrase match.
  *   `sentimentData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SentimentData.t`, *default:* `nil`) - Data specifying sentiment.
  *   `silenceData` (*type:* `GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SilenceData.t`, *default:* `nil`) - Data specifying silence.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :annotationEndBoundary =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary.t()
            | nil,
          :annotationStartBoundary =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary.t()
            | nil,
          :channelTag => integer() | nil,
          :entityMentionData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1EntityMentionData.t()
            | nil,
          :holdData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1HoldData.t()
            | nil,
          :intentMatchData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IntentMatchData.t()
            | nil,
          :interruptionData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1InterruptionData.t()
            | nil,
          :issueMatchData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IssueMatchData.t()
            | nil,
          :phraseMatchData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1PhraseMatchData.t()
            | nil,
          :sentimentData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SentimentData.t()
            | nil,
          :silenceData =>
            GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SilenceData.t()
            | nil
        }

  field(:annotationEndBoundary,
    as:
      GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary
  )

  field(:annotationStartBoundary,
    as:
      GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1AnnotationBoundary
  )

  field(:channelTag)

  field(:entityMentionData,
    as:
      GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1EntityMentionData
  )

  field(:holdData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1HoldData
  )

  field(:intentMatchData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IntentMatchData
  )

  field(:interruptionData,
    as:
      GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1InterruptionData
  )

  field(:issueMatchData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1IssueMatchData
  )

  field(:phraseMatchData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1PhraseMatchData
  )

  field(:sentimentData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SentimentData
  )

  field(:silenceData,
    as: GoogleApi.ContactCenterInsights.V1.Model.GoogleCloudContactcenterinsightsV1SilenceData
  )
end

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

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