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

namespace Google\Cloud\CertificateManager\V1;

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

/**
 * Request for the `CreateCertificateMapEntry` method.
 *
 * Generated from protobuf message <code>google.cloud.certificatemanager.v1.CreateCertificateMapEntryRequest</code>
 */
class CreateCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. The parent resource of the certificate map entry. Must be in the
     * format `projects/&#42;&#47;locations/&#42;&#47;certificateMaps/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     */
    private $parent = '';
    /**
     * Required. A user-provided name of the certificate map entry.
     *
     * Generated from protobuf field <code>string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $certificate_map_entry_id = '';
    /**
     * Required. A definition of the certificate map entry to create.
     *
     * Generated from protobuf field <code>.google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $certificate_map_entry = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $parent
     *           Required. The parent resource of the certificate map entry. Must be in the
     *           format `projects/&#42;&#47;locations/&#42;&#47;certificateMaps/&#42;`.
     *     @type string $certificate_map_entry_id
     *           Required. A user-provided name of the certificate map entry.
     *     @type \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificate_map_entry
     *           Required. A definition of the certificate map entry to create.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. The parent resource of the certificate map entry. Must be in the
     * format `projects/&#42;&#47;locations/&#42;&#47;certificateMaps/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getParent()
    {
        return $this->parent;
    }

    /**
     * Required. The parent resource of the certificate map entry. Must be in the
     * format `projects/&#42;&#47;locations/&#42;&#47;certificateMaps/&#42;`.
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setParent($var)
    {
        GPBUtil::checkString($var, True);
        $this->parent = $var;

        return $this;
    }

    /**
     * Required. A user-provided name of the certificate map entry.
     *
     * Generated from protobuf field <code>string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getCertificateMapEntryId()
    {
        return $this->certificate_map_entry_id;
    }

    /**
     * Required. A user-provided name of the certificate map entry.
     *
     * Generated from protobuf field <code>string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setCertificateMapEntryId($var)
    {
        GPBUtil::checkString($var, True);
        $this->certificate_map_entry_id = $var;

        return $this;
    }

    /**
     * Required. A definition of the certificate map entry to create.
     *
     * Generated from protobuf field <code>.google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\CertificateManager\V1\CertificateMapEntry|null
     */
    public function getCertificateMapEntry()
    {
        return $this->certificate_map_entry;
    }

    public function hasCertificateMapEntry()
    {
        return isset($this->certificate_map_entry);
    }

    public function clearCertificateMapEntry()
    {
        unset($this->certificate_map_entry);
    }

    /**
     * Required. A definition of the certificate map entry to create.
     *
     * Generated from protobuf field <code>.google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $var
     * @return $this
     */
    public function setCertificateMapEntry($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateMapEntry::class);
        $this->certificate_map_entry = $var;

        return $this;
    }

}

