<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/video/transcoder/v1beta1/services.proto

namespace Google\Cloud\Video\Transcoder\V1beta1;

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

/**
 * Request message for `TranscoderService.CreateJobTemplate`.
 *
 * Generated from protobuf message <code>google.cloud.video.transcoder.v1beta1.CreateJobTemplateRequest</code>
 */
class CreateJobTemplateRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. The parent location to create this job template.
     * Format: `projects/{project}/locations/{location}`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     */
    private $parent = '';
    /**
     * Required. Parameters for creating job template.
     *
     * Generated from protobuf field <code>.google.cloud.video.transcoder.v1beta1.JobTemplate job_template = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $job_template = null;
    /**
     * Required. The ID to use for the job template, which will become the final component
     * of the job template's resource name.
     * This value should be 4-63 characters, and valid characters must match the
     * regular expression `[a-zA-Z][a-zA-Z0-9_-]*`.
     *
     * Generated from protobuf field <code>string job_template_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $job_template_id = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $parent
     *           Required. The parent location to create this job template.
     *           Format: `projects/{project}/locations/{location}`
     *     @type \Google\Cloud\Video\Transcoder\V1beta1\JobTemplate $job_template
     *           Required. Parameters for creating job template.
     *     @type string $job_template_id
     *           Required. The ID to use for the job template, which will become the final component
     *           of the job template's resource name.
     *           This value should be 4-63 characters, and valid characters must match the
     *           regular expression `[a-zA-Z][a-zA-Z0-9_-]*`.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Video\Transcoder\V1Beta1\Services::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. The parent location to create this job template.
     * Format: `projects/{project}/locations/{location}`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getParent()
    {
        return $this->parent;
    }

    /**
     * Required. The parent location to create this job template.
     * Format: `projects/{project}/locations/{location}`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setParent($var)
    {
        GPBUtil::checkString($var, True);
        $this->parent = $var;

        return $this;
    }

    /**
     * Required. Parameters for creating job template.
     *
     * Generated from protobuf field <code>.google.cloud.video.transcoder.v1beta1.JobTemplate job_template = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\Video\Transcoder\V1beta1\JobTemplate|null
     */
    public function getJobTemplate()
    {
        return isset($this->job_template) ? $this->job_template : null;
    }

    public function hasJobTemplate()
    {
        return isset($this->job_template);
    }

    public function clearJobTemplate()
    {
        unset($this->job_template);
    }

    /**
     * Required. Parameters for creating job template.
     *
     * Generated from protobuf field <code>.google.cloud.video.transcoder.v1beta1.JobTemplate job_template = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\Video\Transcoder\V1beta1\JobTemplate $var
     * @return $this
     */
    public function setJobTemplate($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Video\Transcoder\V1beta1\JobTemplate::class);
        $this->job_template = $var;

        return $this;
    }

    /**
     * Required. The ID to use for the job template, which will become the final component
     * of the job template's resource name.
     * This value should be 4-63 characters, and valid characters must match the
     * regular expression `[a-zA-Z][a-zA-Z0-9_-]*`.
     *
     * Generated from protobuf field <code>string job_template_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getJobTemplateId()
    {
        return $this->job_template_id;
    }

    /**
     * Required. The ID to use for the job template, which will become the final component
     * of the job template's resource name.
     * This value should be 4-63 characters, and valid characters must match the
     * regular expression `[a-zA-Z][a-zA-Z0-9_-]*`.
     *
     * Generated from protobuf field <code>string job_template_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setJobTemplateId($var)
    {
        GPBUtil::checkString($var, True);
        $this->job_template_id = $var;

        return $this;
    }

}

