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

namespace Google\Cloud\ConfigDelivery\V1;

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

/**
 * ResourceBundleDeploymentInfo represents the status of a resource bundle
 * deployment.
 *
 * Generated from protobuf message <code>google.cloud.configdelivery.v1.ResourceBundleDeploymentInfo</code>
 */
class ResourceBundleDeploymentInfo extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. Refers to a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string release = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     */
    protected $release = '';
    /**
     * Output only. Refers to a version of the `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string version = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $version = '';
    /**
     * Output only. Refers to a variant in a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string variant = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $variant = '';
    /**
     * Output only. Synchronization state of the `ResourceBundle` deployment.
     *
     * Generated from protobuf field <code>.google.cloud.configdelivery.v1.ResourceBundleDeploymentInfo.SyncState sync_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $sync_state = 0;
    /**
     * Output only. Unordered list. Messages contains information related to the
     * `ResourceBundle` deployment. For example, in case of an error, indicate the
     * reason for the error. In case of a pending deployment, reason for why the
     * deployment of new release is pending.
     *
     * Generated from protobuf field <code>repeated string messages = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = UNORDERED_LIST];</code>
     */
    private $messages;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $release
     *           Output only. Refers to a `ResourceBundle` release.
     *     @type string $version
     *           Output only. Refers to a version of the `ResourceBundle` release.
     *     @type string $variant
     *           Output only. Refers to a variant in a `ResourceBundle` release.
     *     @type int $sync_state
     *           Output only. Synchronization state of the `ResourceBundle` deployment.
     *     @type string[] $messages
     *           Output only. Unordered list. Messages contains information related to the
     *           `ResourceBundle` deployment. For example, in case of an error, indicate the
     *           reason for the error. In case of a pending deployment, reason for why the
     *           deployment of new release is pending.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Configdelivery\V1\ConfigDelivery::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. Refers to a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string release = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getRelease()
    {
        return $this->release;
    }

    /**
     * Output only. Refers to a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string release = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setRelease($var)
    {
        GPBUtil::checkString($var, True);
        $this->release = $var;

        return $this;
    }

    /**
     * Output only. Refers to a version of the `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string version = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getVersion()
    {
        return $this->version;
    }

    /**
     * Output only. Refers to a version of the `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string version = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setVersion($var)
    {
        GPBUtil::checkString($var, True);
        $this->version = $var;

        return $this;
    }

    /**
     * Output only. Refers to a variant in a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string variant = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getVariant()
    {
        return $this->variant;
    }

    /**
     * Output only. Refers to a variant in a `ResourceBundle` release.
     *
     * Generated from protobuf field <code>string variant = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setVariant($var)
    {
        GPBUtil::checkString($var, True);
        $this->variant = $var;

        return $this;
    }

    /**
     * Output only. Synchronization state of the `ResourceBundle` deployment.
     *
     * Generated from protobuf field <code>.google.cloud.configdelivery.v1.ResourceBundleDeploymentInfo.SyncState sync_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int
     */
    public function getSyncState()
    {
        return $this->sync_state;
    }

    /**
     * Output only. Synchronization state of the `ResourceBundle` deployment.
     *
     * Generated from protobuf field <code>.google.cloud.configdelivery.v1.ResourceBundleDeploymentInfo.SyncState sync_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int $var
     * @return $this
     */
    public function setSyncState($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\ConfigDelivery\V1\ResourceBundleDeploymentInfo\SyncState::class);
        $this->sync_state = $var;

        return $this;
    }

    /**
     * Output only. Unordered list. Messages contains information related to the
     * `ResourceBundle` deployment. For example, in case of an error, indicate the
     * reason for the error. In case of a pending deployment, reason for why the
     * deployment of new release is pending.
     *
     * Generated from protobuf field <code>repeated string messages = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = UNORDERED_LIST];</code>
     * @return RepeatedField<string>
     */
    public function getMessages()
    {
        return $this->messages;
    }

    /**
     * Output only. Unordered list. Messages contains information related to the
     * `ResourceBundle` deployment. For example, in case of an error, indicate the
     * reason for the error. In case of a pending deployment, reason for why the
     * deployment of new release is pending.
     *
     * Generated from protobuf field <code>repeated string messages = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = UNORDERED_LIST];</code>
     * @param string[] $var
     * @return $this
     */
    public function setMessages($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->messages = $arr;

        return $this;
    }

}

