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

namespace Google\Cloud\VMMigration\V1;

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

/**
 * Holds informatiom about the available versions for upgrade.
 *
 * Generated from protobuf message <code>google.cloud.vmmigration.v1.AvailableUpdates</code>
 */
class AvailableUpdates extends \Google\Protobuf\Internal\Message
{
    /**
     * The newest deployable version of the appliance.
     * The current appliance can't be updated into this version, and the owner
     * must manually deploy this OVA to a new appliance.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion new_deployable_appliance = 1;</code>
     */
    private $new_deployable_appliance = null;
    /**
     * The latest version for in place update.
     * The current appliance can be updated to this version using the API or m4c
     * CLI.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion in_place_update = 2;</code>
     */
    private $in_place_update = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\VMMigration\V1\ApplianceVersion $new_deployable_appliance
     *           The newest deployable version of the appliance.
     *           The current appliance can't be updated into this version, and the owner
     *           must manually deploy this OVA to a new appliance.
     *     @type \Google\Cloud\VMMigration\V1\ApplianceVersion $in_place_update
     *           The latest version for in place update.
     *           The current appliance can be updated to this version using the API or m4c
     *           CLI.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Vmmigration\V1\Vmmigration::initOnce();
        parent::__construct($data);
    }

    /**
     * The newest deployable version of the appliance.
     * The current appliance can't be updated into this version, and the owner
     * must manually deploy this OVA to a new appliance.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion new_deployable_appliance = 1;</code>
     * @return \Google\Cloud\VMMigration\V1\ApplianceVersion|null
     */
    public function getNewDeployableAppliance()
    {
        return $this->new_deployable_appliance;
    }

    public function hasNewDeployableAppliance()
    {
        return isset($this->new_deployable_appliance);
    }

    public function clearNewDeployableAppliance()
    {
        unset($this->new_deployable_appliance);
    }

    /**
     * The newest deployable version of the appliance.
     * The current appliance can't be updated into this version, and the owner
     * must manually deploy this OVA to a new appliance.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion new_deployable_appliance = 1;</code>
     * @param \Google\Cloud\VMMigration\V1\ApplianceVersion $var
     * @return $this
     */
    public function setNewDeployableAppliance($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\VMMigration\V1\ApplianceVersion::class);
        $this->new_deployable_appliance = $var;

        return $this;
    }

    /**
     * The latest version for in place update.
     * The current appliance can be updated to this version using the API or m4c
     * CLI.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion in_place_update = 2;</code>
     * @return \Google\Cloud\VMMigration\V1\ApplianceVersion|null
     */
    public function getInPlaceUpdate()
    {
        return $this->in_place_update;
    }

    public function hasInPlaceUpdate()
    {
        return isset($this->in_place_update);
    }

    public function clearInPlaceUpdate()
    {
        unset($this->in_place_update);
    }

    /**
     * The latest version for in place update.
     * The current appliance can be updated to this version using the API or m4c
     * CLI.
     *
     * Generated from protobuf field <code>.google.cloud.vmmigration.v1.ApplianceVersion in_place_update = 2;</code>
     * @param \Google\Cloud\VMMigration\V1\ApplianceVersion $var
     * @return $this
     */
    public function setInPlaceUpdate($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\VMMigration\V1\ApplianceVersion::class);
        $this->in_place_update = $var;

        return $this;
    }

}

