<?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.InstanceManagedByIgmErrorManagedInstanceError</code>
 */
class InstanceManagedByIgmErrorManagedInstanceError extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. [Output Only] Error code.
     *
     * Generated from protobuf field <code>optional string code = 3059181;</code>
     */
    protected $code = null;
    /**
     * Output only. [Output Only] Error message.
     *
     * Generated from protobuf field <code>optional string message = 418054151;</code>
     */
    protected $message = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $code
     *           Output only. [Output Only] Error code.
     *     @type string $message
     *           Output only. [Output Only] Error message.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. [Output Only] Error code.
     *
     * Generated from protobuf field <code>optional string code = 3059181;</code>
     * @return string
     */
    public function getCode()
    {
        return isset($this->code) ? $this->code : '';
    }

    public function hasCode()
    {
        return isset($this->code);
    }

    public function clearCode()
    {
        unset($this->code);
    }

    /**
     * Output only. [Output Only] Error code.
     *
     * Generated from protobuf field <code>optional string code = 3059181;</code>
     * @param string $var
     * @return $this
     */
    public function setCode($var)
    {
        GPBUtil::checkString($var, True);
        $this->code = $var;

        return $this;
    }

    /**
     * Output only. [Output Only] Error message.
     *
     * Generated from protobuf field <code>optional string message = 418054151;</code>
     * @return string
     */
    public function getMessage()
    {
        return isset($this->message) ? $this->message : '';
    }

    public function hasMessage()
    {
        return isset($this->message);
    }

    public function clearMessage()
    {
        unset($this->message);
    }

    /**
     * Output only. [Output Only] Error message.
     *
     * Generated from protobuf field <code>optional string message = 418054151;</code>
     * @param string $var
     * @return $this
     */
    public function setMessage($var)
    {
        GPBUtil::checkString($var, True);
        $this->message = $var;

        return $this;
    }

}

