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

namespace Google\Cloud\Dataplex\V1;

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

/**
 * DataAttributeBinding represents binding of attributes to resources. Eg: Bind
 * 'CustomerInfo' entity with 'PII' attribute.
 *
 * @deprecated
 * Generated from protobuf message <code>google.cloud.dataplex.v1.DataAttributeBinding</code>
 */
class DataAttributeBinding extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The relative resource name of the Data Attribute Binding, of
     * the form:
     * projects/{project_number}/locations/{location}/dataAttributeBindings/{data_attribute_binding_id}
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     */
    protected $name = '';
    /**
     * Output only. System generated globally unique ID for the
     * DataAttributeBinding. This ID will be different if the DataAttributeBinding
     * is deleted and re-created with the same name.
     *
     * Generated from protobuf field <code>string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $uid = '';
    /**
     * Output only. The time when the DataAttributeBinding was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $create_time = null;
    /**
     * Output only. The time when the DataAttributeBinding was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $update_time = null;
    /**
     * Optional. Description of the DataAttributeBinding.
     *
     * Generated from protobuf field <code>string description = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $description = '';
    /**
     * Optional. User friendly display name.
     *
     * Generated from protobuf field <code>string display_name = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $display_name = '';
    /**
     * Optional. User-defined labels for the DataAttributeBinding.
     *
     * Generated from protobuf field <code>map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $labels;
    /**
     * This checksum is computed by the server based on the value of other
     * fields, and may be sent on update and delete requests to ensure the
     * client has an up-to-date value before proceeding.
     * Etags must be used when calling the DeleteDataAttributeBinding and the
     * UpdateDataAttributeBinding method.
     *
     * Generated from protobuf field <code>string etag = 8;</code>
     */
    protected $etag = '';
    /**
     * Optional. List of attributes to be associated with the resource, provided
     * in the form:
     * projects/{project}/locations/{location}/dataTaxonomies/{dataTaxonomy}/attributes/{data_attribute_id}
     *
     * Generated from protobuf field <code>repeated string attributes = 110 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     */
    private $attributes;
    /**
     * Optional. The list of paths for items within the associated resource (eg.
     * columns and partitions within a table) along with attribute bindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dataplex.v1.DataAttributeBinding.Path paths = 120 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $paths;
    protected $resource_reference;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $name
     *           Output only. The relative resource name of the Data Attribute Binding, of
     *           the form:
     *           projects/{project_number}/locations/{location}/dataAttributeBindings/{data_attribute_binding_id}
     *     @type string $uid
     *           Output only. System generated globally unique ID for the
     *           DataAttributeBinding. This ID will be different if the DataAttributeBinding
     *           is deleted and re-created with the same name.
     *     @type \Google\Protobuf\Timestamp $create_time
     *           Output only. The time when the DataAttributeBinding was created.
     *     @type \Google\Protobuf\Timestamp $update_time
     *           Output only. The time when the DataAttributeBinding was last updated.
     *     @type string $description
     *           Optional. Description of the DataAttributeBinding.
     *     @type string $display_name
     *           Optional. User friendly display name.
     *     @type array|\Google\Protobuf\Internal\MapField $labels
     *           Optional. User-defined labels for the DataAttributeBinding.
     *     @type string $etag
     *           This checksum is computed by the server based on the value of other
     *           fields, and may be sent on update and delete requests to ensure the
     *           client has an up-to-date value before proceeding.
     *           Etags must be used when calling the DeleteDataAttributeBinding and the
     *           UpdateDataAttributeBinding method.
     *     @type string $resource
     *           Optional. Immutable. The resource name of the resource that is associated
     *           to attributes. Presently, only entity resource is supported in the form:
     *           projects/{project}/locations/{location}/lakes/{lake}/zones/{zone}/entities/{entity_id}
     *           Must belong in the same project and region as the attribute binding, and
     *           there can only exist one active binding for a resource.
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $attributes
     *           Optional. List of attributes to be associated with the resource, provided
     *           in the form:
     *           projects/{project}/locations/{location}/dataTaxonomies/{dataTaxonomy}/attributes/{data_attribute_id}
     *     @type array<\Google\Cloud\Dataplex\V1\DataAttributeBinding\Path>|\Google\Protobuf\Internal\RepeatedField $paths
     *           Optional. The list of paths for items within the associated resource (eg.
     *           columns and partitions within a table) along with attribute bindings.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dataplex\V1\DataTaxonomy::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The relative resource name of the Data Attribute Binding, of
     * the form:
     * projects/{project_number}/locations/{location}/dataAttributeBindings/{data_attribute_binding_id}
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Output only. The relative resource name of the Data Attribute Binding, of
     * the form:
     * projects/{project_number}/locations/{location}/dataAttributeBindings/{data_attribute_binding_id}
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * Output only. System generated globally unique ID for the
     * DataAttributeBinding. This ID will be different if the DataAttributeBinding
     * is deleted and re-created with the same name.
     *
     * Generated from protobuf field <code>string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getUid()
    {
        return $this->uid;
    }

    /**
     * Output only. System generated globally unique ID for the
     * DataAttributeBinding. This ID will be different if the DataAttributeBinding
     * is deleted and re-created with the same name.
     *
     * Generated from protobuf field <code>string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setUid($var)
    {
        GPBUtil::checkString($var, True);
        $this->uid = $var;

        return $this;
    }

    /**
     * Output only. The time when the DataAttributeBinding was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getCreateTime()
    {
        return $this->create_time;
    }

    public function hasCreateTime()
    {
        return isset($this->create_time);
    }

    public function clearCreateTime()
    {
        unset($this->create_time);
    }

    /**
     * Output only. The time when the DataAttributeBinding was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setCreateTime($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->create_time = $var;

        return $this;
    }

    /**
     * Output only. The time when the DataAttributeBinding was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getUpdateTime()
    {
        return $this->update_time;
    }

    public function hasUpdateTime()
    {
        return isset($this->update_time);
    }

    public function clearUpdateTime()
    {
        unset($this->update_time);
    }

    /**
     * Output only. The time when the DataAttributeBinding was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setUpdateTime($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->update_time = $var;

        return $this;
    }

    /**
     * Optional. Description of the DataAttributeBinding.
     *
     * Generated from protobuf field <code>string description = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Optional. Description of the DataAttributeBinding.
     *
     * Generated from protobuf field <code>string description = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * Optional. User friendly display name.
     *
     * Generated from protobuf field <code>string display_name = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDisplayName()
    {
        return $this->display_name;
    }

    /**
     * Optional. User friendly display name.
     *
     * Generated from protobuf field <code>string display_name = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setDisplayName($var)
    {
        GPBUtil::checkString($var, True);
        $this->display_name = $var;

        return $this;
    }

    /**
     * Optional. User-defined labels for the DataAttributeBinding.
     *
     * Generated from protobuf field <code>map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return \Google\Protobuf\Internal\MapField
     */
    public function getLabels()
    {
        return $this->labels;
    }

    /**
     * Optional. User-defined labels for the DataAttributeBinding.
     *
     * Generated from protobuf field <code>map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param array|\Google\Protobuf\Internal\MapField $var
     * @return $this
     */
    public function setLabels($var)
    {
        $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING);
        $this->labels = $arr;

        return $this;
    }

    /**
     * This checksum is computed by the server based on the value of other
     * fields, and may be sent on update and delete requests to ensure the
     * client has an up-to-date value before proceeding.
     * Etags must be used when calling the DeleteDataAttributeBinding and the
     * UpdateDataAttributeBinding method.
     *
     * Generated from protobuf field <code>string etag = 8;</code>
     * @return string
     */
    public function getEtag()
    {
        return $this->etag;
    }

    /**
     * This checksum is computed by the server based on the value of other
     * fields, and may be sent on update and delete requests to ensure the
     * client has an up-to-date value before proceeding.
     * Etags must be used when calling the DeleteDataAttributeBinding and the
     * UpdateDataAttributeBinding method.
     *
     * Generated from protobuf field <code>string etag = 8;</code>
     * @param string $var
     * @return $this
     */
    public function setEtag($var)
    {
        GPBUtil::checkString($var, True);
        $this->etag = $var;

        return $this;
    }

    /**
     * Optional. Immutable. The resource name of the resource that is associated
     * to attributes. Presently, only entity resource is supported in the form:
     * projects/{project}/locations/{location}/lakes/{lake}/zones/{zone}/entities/{entity_id}
     * Must belong in the same project and region as the attribute binding, and
     * there can only exist one active binding for a resource.
     *
     * Generated from protobuf field <code>string resource = 100 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return string
     */
    public function getResource()
    {
        return $this->readOneof(100);
    }

    public function hasResource()
    {
        return $this->hasOneof(100);
    }

    /**
     * Optional. Immutable. The resource name of the resource that is associated
     * to attributes. Presently, only entity resource is supported in the form:
     * projects/{project}/locations/{location}/lakes/{lake}/zones/{zone}/entities/{entity_id}
     * Must belong in the same project and region as the attribute binding, and
     * there can only exist one active binding for a resource.
     *
     * Generated from protobuf field <code>string resource = 100 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param string $var
     * @return $this
     */
    public function setResource($var)
    {
        GPBUtil::checkString($var, True);
        $this->writeOneof(100, $var);

        return $this;
    }

    /**
     * Optional. List of attributes to be associated with the resource, provided
     * in the form:
     * projects/{project}/locations/{location}/dataTaxonomies/{dataTaxonomy}/attributes/{data_attribute_id}
     *
     * Generated from protobuf field <code>repeated string attributes = 110 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getAttributes()
    {
        return $this->attributes;
    }

    /**
     * Optional. List of attributes to be associated with the resource, provided
     * in the form:
     * projects/{project}/locations/{location}/dataTaxonomies/{dataTaxonomy}/attributes/{data_attribute_id}
     *
     * Generated from protobuf field <code>repeated string attributes = 110 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setAttributes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->attributes = $arr;

        return $this;
    }

    /**
     * Optional. The list of paths for items within the associated resource (eg.
     * columns and partitions within a table) along with attribute bindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dataplex.v1.DataAttributeBinding.Path paths = 120 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getPaths()
    {
        return $this->paths;
    }

    /**
     * Optional. The list of paths for items within the associated resource (eg.
     * columns and partitions within a table) along with attribute bindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dataplex.v1.DataAttributeBinding.Path paths = 120 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param array<\Google\Cloud\Dataplex\V1\DataAttributeBinding\Path>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setPaths($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dataplex\V1\DataAttributeBinding\Path::class);
        $this->paths = $arr;

        return $this;
    }

    /**
     * @return string
     */
    public function getResourceReference()
    {
        return $this->whichOneof("resource_reference");
    }

}

