/*
 * 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.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.dialogflow.v3beta1.model;

/**
 * Configuration of how speech should be synthesized.
 *
 * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Dialogflow API. For a detailed explanation see:
 * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
 * </p>
 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig extends com.google.api.client.json.GenericJson {

  /**
   * Optional. An identifier which selects 'audio effects' profiles that are applied on (post
   * synthesized) text to speech. Effects are applied on top of each other in the order they are
   * given.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<java.lang.String> effectsProfileId;

  /**
   * Optional. Speaking pitch, in the range [-20.0, 20.0]. 20 means increase 20 semitones from the
   * original pitch. -20 means decrease 20 semitones from the original pitch.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Double pitch;

  /**
   * Optional. Speaking rate/speed, in the range [0.25, 4.0]. 1.0 is the normal native speed
   * supported by the specific voice. 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0),
   * defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0 will return an error.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Double speakingRate;

  /**
   * Optional. The desired voice of the synthesized audio.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleCloudDialogflowCxV3beta1VoiceSelectionParams voice;

  /**
   * Optional. Volume gain (in dB) of the normal native volume supported by the specific voice, in
   * the range [-96.0, 16.0]. If unset, or set to a value of 0.0 (dB), will play at normal native
   * signal amplitude. A value of -6.0 (dB) will play at approximately half the amplitude of the
   * normal native signal amplitude. A value of +6.0 (dB) will play at approximately twice the
   * amplitude of the normal native signal amplitude. We strongly recommend not to exceed +10 (dB)
   * as there's usually no effective increase in loudness for any value greater than that.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Double volumeGainDb;

  /**
   * Optional. An identifier which selects 'audio effects' profiles that are applied on (post
   * synthesized) text to speech. Effects are applied on top of each other in the order they are
   * given.
   * @return value or {@code null} for none
   */
  public java.util.List<java.lang.String> getEffectsProfileId() {
    return effectsProfileId;
  }

  /**
   * Optional. An identifier which selects 'audio effects' profiles that are applied on (post
   * synthesized) text to speech. Effects are applied on top of each other in the order they are
   * given.
   * @param effectsProfileId effectsProfileId or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig setEffectsProfileId(java.util.List<java.lang.String> effectsProfileId) {
    this.effectsProfileId = effectsProfileId;
    return this;
  }

  /**
   * Optional. Speaking pitch, in the range [-20.0, 20.0]. 20 means increase 20 semitones from the
   * original pitch. -20 means decrease 20 semitones from the original pitch.
   * @return value or {@code null} for none
   */
  public java.lang.Double getPitch() {
    return pitch;
  }

  /**
   * Optional. Speaking pitch, in the range [-20.0, 20.0]. 20 means increase 20 semitones from the
   * original pitch. -20 means decrease 20 semitones from the original pitch.
   * @param pitch pitch or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig setPitch(java.lang.Double pitch) {
    this.pitch = pitch;
    return this;
  }

  /**
   * Optional. Speaking rate/speed, in the range [0.25, 4.0]. 1.0 is the normal native speed
   * supported by the specific voice. 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0),
   * defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0 will return an error.
   * @return value or {@code null} for none
   */
  public java.lang.Double getSpeakingRate() {
    return speakingRate;
  }

  /**
   * Optional. Speaking rate/speed, in the range [0.25, 4.0]. 1.0 is the normal native speed
   * supported by the specific voice. 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0),
   * defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0 will return an error.
   * @param speakingRate speakingRate or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig setSpeakingRate(java.lang.Double speakingRate) {
    this.speakingRate = speakingRate;
    return this;
  }

  /**
   * Optional. The desired voice of the synthesized audio.
   * @return value or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1VoiceSelectionParams getVoice() {
    return voice;
  }

  /**
   * Optional. The desired voice of the synthesized audio.
   * @param voice voice or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig setVoice(GoogleCloudDialogflowCxV3beta1VoiceSelectionParams voice) {
    this.voice = voice;
    return this;
  }

  /**
   * Optional. Volume gain (in dB) of the normal native volume supported by the specific voice, in
   * the range [-96.0, 16.0]. If unset, or set to a value of 0.0 (dB), will play at normal native
   * signal amplitude. A value of -6.0 (dB) will play at approximately half the amplitude of the
   * normal native signal amplitude. A value of +6.0 (dB) will play at approximately twice the
   * amplitude of the normal native signal amplitude. We strongly recommend not to exceed +10 (dB)
   * as there's usually no effective increase in loudness for any value greater than that.
   * @return value or {@code null} for none
   */
  public java.lang.Double getVolumeGainDb() {
    return volumeGainDb;
  }

  /**
   * Optional. Volume gain (in dB) of the normal native volume supported by the specific voice, in
   * the range [-96.0, 16.0]. If unset, or set to a value of 0.0 (dB), will play at normal native
   * signal amplitude. A value of -6.0 (dB) will play at approximately half the amplitude of the
   * normal native signal amplitude. A value of +6.0 (dB) will play at approximately twice the
   * amplitude of the normal native signal amplitude. We strongly recommend not to exceed +10 (dB)
   * as there's usually no effective increase in loudness for any value greater than that.
   * @param volumeGainDb volumeGainDb or {@code null} for none
   */
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig setVolumeGainDb(java.lang.Double volumeGainDb) {
    this.volumeGainDb = volumeGainDb;
    return this;
  }

  @Override
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig set(String fieldName, Object value) {
    return (GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig) super.set(fieldName, value);
  }

  @Override
  public GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig clone() {
    return (GoogleCloudDialogflowCxV3beta1SynthesizeSpeechConfig) super.clone();
  }

}
