<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/texttospeech/v1/cloud_tts_lrs.proto

namespace Google\Cloud\TextToSpeech\V1;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * The top-level message sent by the client for the
 * `SynthesizeLongAudio` method.
 *
 * Generated from protobuf message <code>google.cloud.texttospeech.v1.SynthesizeLongAudioRequest</code>
 */
class SynthesizeLongAudioRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * The resource states of the request in the form of
     * `projects/&#42;&#47;locations/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1;</code>
     */
    private $parent = '';
    /**
     * Required. The Synthesizer requires either plain text or SSML as input.
     * While Long Audio is in preview, SSML is temporarily unsupported.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.SynthesisInput input = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $input = null;
    /**
     * Required. The configuration of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.AudioConfig audio_config = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $audio_config = null;
    /**
     * Required. Specifies a Cloud Storage URI for the synthesis results. Must be
     * specified in the format: `gs://bucket_name/object_name`, and the bucket
     * must already exist.
     *
     * Generated from protobuf field <code>string output_gcs_uri = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $output_gcs_uri = '';
    /**
     * Required. The desired voice of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.VoiceSelectionParams voice = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $voice = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $parent
     *           The resource states of the request in the form of
     *           `projects/&#42;&#47;locations/&#42;`.
     *     @type \Google\Cloud\TextToSpeech\V1\SynthesisInput $input
     *           Required. The Synthesizer requires either plain text or SSML as input.
     *           While Long Audio is in preview, SSML is temporarily unsupported.
     *     @type \Google\Cloud\TextToSpeech\V1\AudioConfig $audio_config
     *           Required. The configuration of the synthesized audio.
     *     @type string $output_gcs_uri
     *           Required. Specifies a Cloud Storage URI for the synthesis results. Must be
     *           specified in the format: `gs://bucket_name/object_name`, and the bucket
     *           must already exist.
     *     @type \Google\Cloud\TextToSpeech\V1\VoiceSelectionParams $voice
     *           Required. The desired voice of the synthesized audio.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Texttospeech\V1\CloudTtsLrs::initOnce();
        parent::__construct($data);
    }

    /**
     * The resource states of the request in the form of
     * `projects/&#42;&#47;locations/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1;</code>
     * @return string
     */
    public function getParent()
    {
        return $this->parent;
    }

    /**
     * The resource states of the request in the form of
     * `projects/&#42;&#47;locations/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setParent($var)
    {
        GPBUtil::checkString($var, True);
        $this->parent = $var;

        return $this;
    }

    /**
     * Required. The Synthesizer requires either plain text or SSML as input.
     * While Long Audio is in preview, SSML is temporarily unsupported.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.SynthesisInput input = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\TextToSpeech\V1\SynthesisInput|null
     */
    public function getInput()
    {
        return $this->input;
    }

    public function hasInput()
    {
        return isset($this->input);
    }

    public function clearInput()
    {
        unset($this->input);
    }

    /**
     * Required. The Synthesizer requires either plain text or SSML as input.
     * While Long Audio is in preview, SSML is temporarily unsupported.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.SynthesisInput input = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\TextToSpeech\V1\SynthesisInput $var
     * @return $this
     */
    public function setInput($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\TextToSpeech\V1\SynthesisInput::class);
        $this->input = $var;

        return $this;
    }

    /**
     * Required. The configuration of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.AudioConfig audio_config = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\TextToSpeech\V1\AudioConfig|null
     */
    public function getAudioConfig()
    {
        return $this->audio_config;
    }

    public function hasAudioConfig()
    {
        return isset($this->audio_config);
    }

    public function clearAudioConfig()
    {
        unset($this->audio_config);
    }

    /**
     * Required. The configuration of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.AudioConfig audio_config = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\TextToSpeech\V1\AudioConfig $var
     * @return $this
     */
    public function setAudioConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\TextToSpeech\V1\AudioConfig::class);
        $this->audio_config = $var;

        return $this;
    }

    /**
     * Required. Specifies a Cloud Storage URI for the synthesis results. Must be
     * specified in the format: `gs://bucket_name/object_name`, and the bucket
     * must already exist.
     *
     * Generated from protobuf field <code>string output_gcs_uri = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getOutputGcsUri()
    {
        return $this->output_gcs_uri;
    }

    /**
     * Required. Specifies a Cloud Storage URI for the synthesis results. Must be
     * specified in the format: `gs://bucket_name/object_name`, and the bucket
     * must already exist.
     *
     * Generated from protobuf field <code>string output_gcs_uri = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setOutputGcsUri($var)
    {
        GPBUtil::checkString($var, True);
        $this->output_gcs_uri = $var;

        return $this;
    }

    /**
     * Required. The desired voice of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.VoiceSelectionParams voice = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\TextToSpeech\V1\VoiceSelectionParams|null
     */
    public function getVoice()
    {
        return $this->voice;
    }

    public function hasVoice()
    {
        return isset($this->voice);
    }

    public function clearVoice()
    {
        unset($this->voice);
    }

    /**
     * Required. The desired voice of the synthesized audio.
     *
     * Generated from protobuf field <code>.google.cloud.texttospeech.v1.VoiceSelectionParams voice = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\TextToSpeech\V1\VoiceSelectionParams $var
     * @return $this
     */
    public function setVoice($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\TextToSpeech\V1\VoiceSelectionParams::class);
        $this->voice = $var;

        return $this;
    }

}

