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

namespace Google\Cloud\AppEngine\V1;

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

/**
 * Request message for `AuthorizedCertificates.UpdateAuthorizedCertificate`.
 *
 * Generated from protobuf message <code>google.appengine.v1.UpdateAuthorizedCertificateRequest</code>
 */
class UpdateAuthorizedCertificateRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Name of the resource to update. Example:
     * `apps/myapp/authorizedCertificates/12345`.
     *
     * Generated from protobuf field <code>string name = 1;</code>
     */
    private $name = '';
    /**
     * An `AuthorizedCertificate` containing the updated resource. Only fields set
     * in the field mask will be updated.
     *
     * Generated from protobuf field <code>.google.appengine.v1.AuthorizedCertificate certificate = 2;</code>
     */
    private $certificate = null;
    /**
     * Standard field mask for the set of fields to be updated. Updates are only
     * supported on the `certificate_raw_data` and `display_name` fields.
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 3;</code>
     */
    private $update_mask = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $name
     *           Name of the resource to update. Example:
     *           `apps/myapp/authorizedCertificates/12345`.
     *     @type \Google\Cloud\AppEngine\V1\AuthorizedCertificate $certificate
     *           An `AuthorizedCertificate` containing the updated resource. Only fields set
     *           in the field mask will be updated.
     *     @type \Google\Protobuf\FieldMask $update_mask
     *           Standard field mask for the set of fields to be updated. Updates are only
     *           supported on the `certificate_raw_data` and `display_name` fields.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Appengine\V1\Appengine::initOnce();
        parent::__construct($data);
    }

    /**
     * Name of the resource to update. Example:
     * `apps/myapp/authorizedCertificates/12345`.
     *
     * Generated from protobuf field <code>string name = 1;</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Name of the resource to update. Example:
     * `apps/myapp/authorizedCertificates/12345`.
     *
     * Generated from protobuf field <code>string name = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * An `AuthorizedCertificate` containing the updated resource. Only fields set
     * in the field mask will be updated.
     *
     * Generated from protobuf field <code>.google.appengine.v1.AuthorizedCertificate certificate = 2;</code>
     * @return \Google\Cloud\AppEngine\V1\AuthorizedCertificate|null
     */
    public function getCertificate()
    {
        return $this->certificate;
    }

    public function hasCertificate()
    {
        return isset($this->certificate);
    }

    public function clearCertificate()
    {
        unset($this->certificate);
    }

    /**
     * An `AuthorizedCertificate` containing the updated resource. Only fields set
     * in the field mask will be updated.
     *
     * Generated from protobuf field <code>.google.appengine.v1.AuthorizedCertificate certificate = 2;</code>
     * @param \Google\Cloud\AppEngine\V1\AuthorizedCertificate $var
     * @return $this
     */
    public function setCertificate($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\AppEngine\V1\AuthorizedCertificate::class);
        $this->certificate = $var;

        return $this;
    }

    /**
     * Standard field mask for the set of fields to be updated. Updates are only
     * supported on the `certificate_raw_data` and `display_name` fields.
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 3;</code>
     * @return \Google\Protobuf\FieldMask|null
     */
    public function getUpdateMask()
    {
        return $this->update_mask;
    }

    public function hasUpdateMask()
    {
        return isset($this->update_mask);
    }

    public function clearUpdateMask()
    {
        unset($this->update_mask);
    }

    /**
     * Standard field mask for the set of fields to be updated. Updates are only
     * supported on the `certificate_raw_data` and `display_name` fields.
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 3;</code>
     * @param \Google\Protobuf\FieldMask $var
     * @return $this
     */
    public function setUpdateMask($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class);
        $this->update_mask = $var;

        return $this;
    }

}

