<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/orchestration/airflow/service/v1/image_versions.proto

namespace Google\Cloud\Orchestration\Airflow\Service\V1;

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

/**
 * ImageVersion information
 *
 * Generated from protobuf message <code>google.cloud.orchestration.airflow.service.v1.ImageVersion</code>
 */
class ImageVersion extends \Google\Protobuf\Internal\Message
{
    /**
     * The string identifier of the ImageVersion, in the form:
     * "composer-x.y.z-airflow-a.b.c"
     *
     * Generated from protobuf field <code>string image_version_id = 1;</code>
     */
    protected $image_version_id = '';
    /**
     * Whether this is the default ImageVersion used by Composer during
     * environment creation if no input ImageVersion is specified.
     *
     * Generated from protobuf field <code>bool is_default = 2;</code>
     */
    protected $is_default = false;
    /**
     * supported python versions
     *
     * Generated from protobuf field <code>repeated string supported_python_versions = 3;</code>
     */
    private $supported_python_versions;
    /**
     * The date of the version release.
     *
     * Generated from protobuf field <code>.google.type.Date release_date = 4;</code>
     */
    protected $release_date = null;
    /**
     * Whether it is impossible to create an environment with the image version.
     *
     * Generated from protobuf field <code>bool creation_disabled = 5;</code>
     */
    protected $creation_disabled = false;
    /**
     * Whether it is impossible to upgrade an environment running with the image
     * version.
     *
     * Generated from protobuf field <code>bool upgrade_disabled = 6;</code>
     */
    protected $upgrade_disabled = false;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $image_version_id
     *           The string identifier of the ImageVersion, in the form:
     *           "composer-x.y.z-airflow-a.b.c"
     *     @type bool $is_default
     *           Whether this is the default ImageVersion used by Composer during
     *           environment creation if no input ImageVersion is specified.
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $supported_python_versions
     *           supported python versions
     *     @type \Google\Type\Date $release_date
     *           The date of the version release.
     *     @type bool $creation_disabled
     *           Whether it is impossible to create an environment with the image version.
     *     @type bool $upgrade_disabled
     *           Whether it is impossible to upgrade an environment running with the image
     *           version.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Orchestration\Airflow\Service\V1\ImageVersions::initOnce();
        parent::__construct($data);
    }

    /**
     * The string identifier of the ImageVersion, in the form:
     * "composer-x.y.z-airflow-a.b.c"
     *
     * Generated from protobuf field <code>string image_version_id = 1;</code>
     * @return string
     */
    public function getImageVersionId()
    {
        return $this->image_version_id;
    }

    /**
     * The string identifier of the ImageVersion, in the form:
     * "composer-x.y.z-airflow-a.b.c"
     *
     * Generated from protobuf field <code>string image_version_id = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setImageVersionId($var)
    {
        GPBUtil::checkString($var, True);
        $this->image_version_id = $var;

        return $this;
    }

    /**
     * Whether this is the default ImageVersion used by Composer during
     * environment creation if no input ImageVersion is specified.
     *
     * Generated from protobuf field <code>bool is_default = 2;</code>
     * @return bool
     */
    public function getIsDefault()
    {
        return $this->is_default;
    }

    /**
     * Whether this is the default ImageVersion used by Composer during
     * environment creation if no input ImageVersion is specified.
     *
     * Generated from protobuf field <code>bool is_default = 2;</code>
     * @param bool $var
     * @return $this
     */
    public function setIsDefault($var)
    {
        GPBUtil::checkBool($var);
        $this->is_default = $var;

        return $this;
    }

    /**
     * supported python versions
     *
     * Generated from protobuf field <code>repeated string supported_python_versions = 3;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getSupportedPythonVersions()
    {
        return $this->supported_python_versions;
    }

    /**
     * supported python versions
     *
     * Generated from protobuf field <code>repeated string supported_python_versions = 3;</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setSupportedPythonVersions($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->supported_python_versions = $arr;

        return $this;
    }

    /**
     * The date of the version release.
     *
     * Generated from protobuf field <code>.google.type.Date release_date = 4;</code>
     * @return \Google\Type\Date|null
     */
    public function getReleaseDate()
    {
        return $this->release_date;
    }

    public function hasReleaseDate()
    {
        return isset($this->release_date);
    }

    public function clearReleaseDate()
    {
        unset($this->release_date);
    }

    /**
     * The date of the version release.
     *
     * Generated from protobuf field <code>.google.type.Date release_date = 4;</code>
     * @param \Google\Type\Date $var
     * @return $this
     */
    public function setReleaseDate($var)
    {
        GPBUtil::checkMessage($var, \Google\Type\Date::class);
        $this->release_date = $var;

        return $this;
    }

    /**
     * Whether it is impossible to create an environment with the image version.
     *
     * Generated from protobuf field <code>bool creation_disabled = 5;</code>
     * @return bool
     */
    public function getCreationDisabled()
    {
        return $this->creation_disabled;
    }

    /**
     * Whether it is impossible to create an environment with the image version.
     *
     * Generated from protobuf field <code>bool creation_disabled = 5;</code>
     * @param bool $var
     * @return $this
     */
    public function setCreationDisabled($var)
    {
        GPBUtil::checkBool($var);
        $this->creation_disabled = $var;

        return $this;
    }

    /**
     * Whether it is impossible to upgrade an environment running with the image
     * version.
     *
     * Generated from protobuf field <code>bool upgrade_disabled = 6;</code>
     * @return bool
     */
    public function getUpgradeDisabled()
    {
        return $this->upgrade_disabled;
    }

    /**
     * Whether it is impossible to upgrade an environment running with the image
     * version.
     *
     * Generated from protobuf field <code>bool upgrade_disabled = 6;</code>
     * @param bool $var
     * @return $this
     */
    public function setUpgradeDisabled($var)
    {
        GPBUtil::checkBool($var);
        $this->upgrade_disabled = $var;

        return $this;
    }

}

