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

namespace Google\Cloud\Dataplex\V1;

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

/**
 * Represents tables and fileset metadata contained within a zone.
 *
 * Generated from protobuf message <code>google.cloud.dataplex.v1.Entity</code>
 */
class Entity extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The resource name of the entity, of the form:
     * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{id}`.
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     */
    private $name = '';
    /**
     * Optional. Display name must be shorter than or equal to 256 characters.
     *
     * Generated from protobuf field <code>string display_name = 2 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $display_name = '';
    /**
     * Optional. User friendly longer description text. Must be shorter than or
     * equal to 1024 characters.
     *
     * Generated from protobuf field <code>string description = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $description = '';
    /**
     * Output only. The time when the entity was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $create_time = null;
    /**
     * Output only. The time when the entity was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $update_time = null;
    /**
     * Required. A user-provided entity ID. It is mutable, and will be used as the
     * published table name. Specifying a new ID in an update entity
     * request will override the existing value.
     * The ID must contain only letters (a-z, A-Z), numbers (0-9), and
     * underscores. Must begin with a letter and consist of 256 or fewer
     * characters.
     *
     * Generated from protobuf field <code>string id = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $id = '';
    /**
     * Optional. The etag associated with the entity, which can be retrieved with
     * a [GetEntity][] request. Required for update and delete requests.
     *
     * Generated from protobuf field <code>string etag = 8 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $etag = '';
    /**
     * Required. Immutable. The type of entity.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.Type type = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $type = 0;
    /**
     * Required. Immutable. The ID of the asset associated with the storage
     * location containing the entity data. The entity must be with in the same
     * zone with the asset.
     *
     * Generated from protobuf field <code>string asset = 11 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $asset = '';
    /**
     * Required. Immutable. The storage path of the entity data.
     * For Cloud Storage data, this is the fully-qualified path to the entity,
     * such as `gs://bucket/path/to/data`. For BigQuery data, this is the name of
     * the table resource, such as
     * `projects/project_id/datasets/dataset_id/tables/table_id`.
     *
     * Generated from protobuf field <code>string data_path = 12 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $data_path = '';
    /**
     * Optional. The set of items within the data path constituting the data in
     * the entity, represented as a glob path. Example:
     * `gs://bucket/path/to/data/&#42;*&#47;&#42;.csv`.
     *
     * Generated from protobuf field <code>string data_path_pattern = 13 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $data_path_pattern = '';
    /**
     * Output only. The name of the associated Data Catalog entry.
     *
     * Generated from protobuf field <code>string catalog_entry = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $catalog_entry = '';
    /**
     * Required. Immutable. Identifies the storage system of the entity data.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageSystem system = 15 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $system = 0;
    /**
     * Required. Identifies the storage format of the entity data.
     * It does not apply to entities with data stored in BigQuery.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageFormat format = 16 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $format = null;
    /**
     * Output only. Metadata stores that the entity is compatible with.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.CompatibilityStatus compatibility = 19 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $compatibility = null;
    /**
     * Required. The description of the data structure and layout.
     * The schema is not included in list responses. It is only included in
     * `SCHEMA` and `FULL` entity views of a `GetEntity` response.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Schema schema = 50 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $schema = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $name
     *           Output only. The resource name of the entity, of the form:
     *           `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{id}`.
     *     @type string $display_name
     *           Optional. Display name must be shorter than or equal to 256 characters.
     *     @type string $description
     *           Optional. User friendly longer description text. Must be shorter than or
     *           equal to 1024 characters.
     *     @type \Google\Protobuf\Timestamp $create_time
     *           Output only. The time when the entity was created.
     *     @type \Google\Protobuf\Timestamp $update_time
     *           Output only. The time when the entity was last updated.
     *     @type string $id
     *           Required. A user-provided entity ID. It is mutable, and will be used as the
     *           published table name. Specifying a new ID in an update entity
     *           request will override the existing value.
     *           The ID must contain only letters (a-z, A-Z), numbers (0-9), and
     *           underscores. Must begin with a letter and consist of 256 or fewer
     *           characters.
     *     @type string $etag
     *           Optional. The etag associated with the entity, which can be retrieved with
     *           a [GetEntity][] request. Required for update and delete requests.
     *     @type int $type
     *           Required. Immutable. The type of entity.
     *     @type string $asset
     *           Required. Immutable. The ID of the asset associated with the storage
     *           location containing the entity data. The entity must be with in the same
     *           zone with the asset.
     *     @type string $data_path
     *           Required. Immutable. The storage path of the entity data.
     *           For Cloud Storage data, this is the fully-qualified path to the entity,
     *           such as `gs://bucket/path/to/data`. For BigQuery data, this is the name of
     *           the table resource, such as
     *           `projects/project_id/datasets/dataset_id/tables/table_id`.
     *     @type string $data_path_pattern
     *           Optional. The set of items within the data path constituting the data in
     *           the entity, represented as a glob path. Example:
     *           `gs://bucket/path/to/data/&#42;*&#47;&#42;.csv`.
     *     @type string $catalog_entry
     *           Output only. The name of the associated Data Catalog entry.
     *     @type int $system
     *           Required. Immutable. Identifies the storage system of the entity data.
     *     @type \Google\Cloud\Dataplex\V1\StorageFormat $format
     *           Required. Identifies the storage format of the entity data.
     *           It does not apply to entities with data stored in BigQuery.
     *     @type \Google\Cloud\Dataplex\V1\Entity\CompatibilityStatus $compatibility
     *           Output only. Metadata stores that the entity is compatible with.
     *     @type \Google\Cloud\Dataplex\V1\Schema $schema
     *           Required. The description of the data structure and layout.
     *           The schema is not included in list responses. It is only included in
     *           `SCHEMA` and `FULL` entity views of a `GetEntity` response.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dataplex\V1\Metadata::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The resource name of the entity, of the form:
     * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{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 resource name of the entity, of the form:
     * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{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;
    }

    /**
     * Optional. Display name must be shorter than or equal to 256 characters.
     *
     * Generated from protobuf field <code>string display_name = 2 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDisplayName()
    {
        return $this->display_name;
    }

    /**
     * Optional. Display name must be shorter than or equal to 256 characters.
     *
     * Generated from protobuf field <code>string display_name = 2 [(.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 friendly longer description text. Must be shorter than or
     * equal to 1024 characters.
     *
     * Generated from protobuf field <code>string description = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Optional. User friendly longer description text. Must be shorter than or
     * equal to 1024 characters.
     *
     * Generated from protobuf field <code>string description = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * Output only. The time when the entity was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 5 [(.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 entity was created.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 5 [(.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 entity was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 6 [(.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 entity was last updated.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 6 [(.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;
    }

    /**
     * Required. A user-provided entity ID. It is mutable, and will be used as the
     * published table name. Specifying a new ID in an update entity
     * request will override the existing value.
     * The ID must contain only letters (a-z, A-Z), numbers (0-9), and
     * underscores. Must begin with a letter and consist of 256 or fewer
     * characters.
     *
     * Generated from protobuf field <code>string id = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Required. A user-provided entity ID. It is mutable, and will be used as the
     * published table name. Specifying a new ID in an update entity
     * request will override the existing value.
     * The ID must contain only letters (a-z, A-Z), numbers (0-9), and
     * underscores. Must begin with a letter and consist of 256 or fewer
     * characters.
     *
     * Generated from protobuf field <code>string id = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setId($var)
    {
        GPBUtil::checkString($var, True);
        $this->id = $var;

        return $this;
    }

    /**
     * Optional. The etag associated with the entity, which can be retrieved with
     * a [GetEntity][] request. Required for update and delete requests.
     *
     * Generated from protobuf field <code>string etag = 8 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getEtag()
    {
        return $this->etag;
    }

    /**
     * Optional. The etag associated with the entity, which can be retrieved with
     * a [GetEntity][] request. Required for update and delete requests.
     *
     * Generated from protobuf field <code>string etag = 8 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setEtag($var)
    {
        GPBUtil::checkString($var, True);
        $this->etag = $var;

        return $this;
    }

    /**
     * Required. Immutable. The type of entity.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.Type type = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return int
     */
    public function getType()
    {
        return $this->type;
    }

    /**
     * Required. Immutable. The type of entity.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.Type type = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param int $var
     * @return $this
     */
    public function setType($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\Dataplex\V1\Entity\Type::class);
        $this->type = $var;

        return $this;
    }

    /**
     * Required. Immutable. The ID of the asset associated with the storage
     * location containing the entity data. The entity must be with in the same
     * zone with the asset.
     *
     * Generated from protobuf field <code>string asset = 11 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return string
     */
    public function getAsset()
    {
        return $this->asset;
    }

    /**
     * Required. Immutable. The ID of the asset associated with the storage
     * location containing the entity data. The entity must be with in the same
     * zone with the asset.
     *
     * Generated from protobuf field <code>string asset = 11 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param string $var
     * @return $this
     */
    public function setAsset($var)
    {
        GPBUtil::checkString($var, True);
        $this->asset = $var;

        return $this;
    }

    /**
     * Required. Immutable. The storage path of the entity data.
     * For Cloud Storage data, this is the fully-qualified path to the entity,
     * such as `gs://bucket/path/to/data`. For BigQuery data, this is the name of
     * the table resource, such as
     * `projects/project_id/datasets/dataset_id/tables/table_id`.
     *
     * Generated from protobuf field <code>string data_path = 12 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return string
     */
    public function getDataPath()
    {
        return $this->data_path;
    }

    /**
     * Required. Immutable. The storage path of the entity data.
     * For Cloud Storage data, this is the fully-qualified path to the entity,
     * such as `gs://bucket/path/to/data`. For BigQuery data, this is the name of
     * the table resource, such as
     * `projects/project_id/datasets/dataset_id/tables/table_id`.
     *
     * Generated from protobuf field <code>string data_path = 12 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param string $var
     * @return $this
     */
    public function setDataPath($var)
    {
        GPBUtil::checkString($var, True);
        $this->data_path = $var;

        return $this;
    }

    /**
     * Optional. The set of items within the data path constituting the data in
     * the entity, represented as a glob path. Example:
     * `gs://bucket/path/to/data/&#42;*&#47;&#42;.csv`.
     *
     * Generated from protobuf field <code>string data_path_pattern = 13 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDataPathPattern()
    {
        return $this->data_path_pattern;
    }

    /**
     * Optional. The set of items within the data path constituting the data in
     * the entity, represented as a glob path. Example:
     * `gs://bucket/path/to/data/&#42;*&#47;&#42;.csv`.
     *
     * Generated from protobuf field <code>string data_path_pattern = 13 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setDataPathPattern($var)
    {
        GPBUtil::checkString($var, True);
        $this->data_path_pattern = $var;

        return $this;
    }

    /**
     * Output only. The name of the associated Data Catalog entry.
     *
     * Generated from protobuf field <code>string catalog_entry = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getCatalogEntry()
    {
        return $this->catalog_entry;
    }

    /**
     * Output only. The name of the associated Data Catalog entry.
     *
     * Generated from protobuf field <code>string catalog_entry = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setCatalogEntry($var)
    {
        GPBUtil::checkString($var, True);
        $this->catalog_entry = $var;

        return $this;
    }

    /**
     * Required. Immutable. Identifies the storage system of the entity data.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageSystem system = 15 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return int
     */
    public function getSystem()
    {
        return $this->system;
    }

    /**
     * Required. Immutable. Identifies the storage system of the entity data.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageSystem system = 15 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param int $var
     * @return $this
     */
    public function setSystem($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\Dataplex\V1\StorageSystem::class);
        $this->system = $var;

        return $this;
    }

    /**
     * Required. Identifies the storage format of the entity data.
     * It does not apply to entities with data stored in BigQuery.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageFormat format = 16 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\Dataplex\V1\StorageFormat|null
     */
    public function getFormat()
    {
        return $this->format;
    }

    public function hasFormat()
    {
        return isset($this->format);
    }

    public function clearFormat()
    {
        unset($this->format);
    }

    /**
     * Required. Identifies the storage format of the entity data.
     * It does not apply to entities with data stored in BigQuery.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.StorageFormat format = 16 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\Dataplex\V1\StorageFormat $var
     * @return $this
     */
    public function setFormat($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dataplex\V1\StorageFormat::class);
        $this->format = $var;

        return $this;
    }

    /**
     * Output only. Metadata stores that the entity is compatible with.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.CompatibilityStatus compatibility = 19 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Cloud\Dataplex\V1\Entity\CompatibilityStatus|null
     */
    public function getCompatibility()
    {
        return $this->compatibility;
    }

    public function hasCompatibility()
    {
        return isset($this->compatibility);
    }

    public function clearCompatibility()
    {
        unset($this->compatibility);
    }

    /**
     * Output only. Metadata stores that the entity is compatible with.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Entity.CompatibilityStatus compatibility = 19 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Cloud\Dataplex\V1\Entity\CompatibilityStatus $var
     * @return $this
     */
    public function setCompatibility($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dataplex\V1\Entity\CompatibilityStatus::class);
        $this->compatibility = $var;

        return $this;
    }

    /**
     * Required. The description of the data structure and layout.
     * The schema is not included in list responses. It is only included in
     * `SCHEMA` and `FULL` entity views of a `GetEntity` response.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Schema schema = 50 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\Dataplex\V1\Schema|null
     */
    public function getSchema()
    {
        return $this->schema;
    }

    public function hasSchema()
    {
        return isset($this->schema);
    }

    public function clearSchema()
    {
        unset($this->schema);
    }

    /**
     * Required. The description of the data structure and layout.
     * The schema is not included in list responses. It is only included in
     * `SCHEMA` and `FULL` entity views of a `GetEntity` response.
     *
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.Schema schema = 50 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\Dataplex\V1\Schema $var
     * @return $this
     */
    public function setSchema($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dataplex\V1\Schema::class);
        $this->schema = $var;

        return $this;
    }

}

