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

namespace Google\Cloud\Deploy\V1;

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

/**
 * DeployJobRunMetadata surfaces information associated with a `DeployJobRun` to
 * the user.
 *
 * Generated from protobuf message <code>google.cloud.deploy.v1.DeployJobRunMetadata</code>
 */
class DeployJobRunMetadata extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The name of the Cloud Run Service that is associated with a `DeployJobRun`.
     *
     * Generated from protobuf field <code>.google.cloud.deploy.v1.CloudRunMetadata cloud_run = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $cloud_run = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Deploy\V1\CloudRunMetadata $cloud_run
     *           Output only. The name of the Cloud Run Service that is associated with a `DeployJobRun`.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Deploy\V1\CloudDeploy::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The name of the Cloud Run Service that is associated with a `DeployJobRun`.
     *
     * Generated from protobuf field <code>.google.cloud.deploy.v1.CloudRunMetadata cloud_run = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Cloud\Deploy\V1\CloudRunMetadata|null
     */
    public function getCloudRun()
    {
        return $this->cloud_run;
    }

    public function hasCloudRun()
    {
        return isset($this->cloud_run);
    }

    public function clearCloudRun()
    {
        unset($this->cloud_run);
    }

    /**
     * Output only. The name of the Cloud Run Service that is associated with a `DeployJobRun`.
     *
     * Generated from protobuf field <code>.google.cloud.deploy.v1.CloudRunMetadata cloud_run = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Cloud\Deploy\V1\CloudRunMetadata $var
     * @return $this
     */
    public function setCloudRun($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Deploy\V1\CloudRunMetadata::class);
        $this->cloud_run = $var;

        return $this;
    }

}

