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

namespace Google\Cloud\Compute\V1;

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

/**
 *
 * Generated from protobuf message <code>google.cloud.compute.v1.ImageFamilyView</code>
 */
class ImageFamilyView extends \Google\Protobuf\Internal\Message
{
    /**
     * The latest image that is part of the specified image family in the requested location, and that is not deprecated.
     *
     * Generated from protobuf field <code>optional .google.cloud.compute.v1.Image image = 100313435;</code>
     */
    private $image = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Compute\V1\Image $image
     *           The latest image that is part of the specified image family in the requested location, and that is not deprecated.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * The latest image that is part of the specified image family in the requested location, and that is not deprecated.
     *
     * Generated from protobuf field <code>optional .google.cloud.compute.v1.Image image = 100313435;</code>
     * @return \Google\Cloud\Compute\V1\Image|null
     */
    public function getImage()
    {
        return $this->image;
    }

    public function hasImage()
    {
        return isset($this->image);
    }

    public function clearImage()
    {
        unset($this->image);
    }

    /**
     * The latest image that is part of the specified image family in the requested location, and that is not deprecated.
     *
     * Generated from protobuf field <code>optional .google.cloud.compute.v1.Image image = 100313435;</code>
     * @param \Google\Cloud\Compute\V1\Image $var
     * @return $this
     */
    public function setImage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Compute\V1\Image::class);
        $this->image = $var;

        return $this;
    }

}

