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

namespace Google\Cloud\Dataplex\V1;

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

/**
 * An aspect is a single piece of metadata describing an entry.
 *
 * Generated from protobuf message <code>google.cloud.dataplex.v1.Aspect</code>
 */
class Aspect extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The resource name of the type used to create this Aspect.
     *
     * Generated from protobuf field <code>string aspect_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $aspect_type = '';
    /**
     * Output only. The path in the entry under which the aspect is attached.
     *
     * Generated from protobuf field <code>string path = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $path = '';
    /**
     * Output only. The time when the Aspect 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 Aspect 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;
    /**
     * Required. The content of the aspect, according to its aspect type schema.
     * This will replace `content`.
     * The maximum size of the field is 120KB (encoded as UTF-8).
     *
     * Generated from protobuf field <code>.google.protobuf.Struct data = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $data = null;
    /**
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.AspectSource aspect_source = 9 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $aspect_source = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $aspect_type
     *           Output only. The resource name of the type used to create this Aspect.
     *     @type string $path
     *           Output only. The path in the entry under which the aspect is attached.
     *     @type \Google\Protobuf\Timestamp $create_time
     *           Output only. The time when the Aspect was created.
     *     @type \Google\Protobuf\Timestamp $update_time
     *           Output only. The time when the Aspect was last updated.
     *     @type \Google\Protobuf\Struct $data
     *           Required. The content of the aspect, according to its aspect type schema.
     *           This will replace `content`.
     *           The maximum size of the field is 120KB (encoded as UTF-8).
     *     @type \Google\Cloud\Dataplex\V1\AspectSource $aspect_source
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dataplex\V1\Catalog::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The resource name of the type used to create this Aspect.
     *
     * Generated from protobuf field <code>string aspect_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getAspectType()
    {
        return $this->aspect_type;
    }

    /**
     * Output only. The resource name of the type used to create this Aspect.
     *
     * Generated from protobuf field <code>string aspect_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setAspectType($var)
    {
        GPBUtil::checkString($var, True);
        $this->aspect_type = $var;

        return $this;
    }

    /**
     * Output only. The path in the entry under which the aspect is attached.
     *
     * Generated from protobuf field <code>string path = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getPath()
    {
        return $this->path;
    }

    /**
     * Output only. The path in the entry under which the aspect is attached.
     *
     * Generated from protobuf field <code>string path = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setPath($var)
    {
        GPBUtil::checkString($var, True);
        $this->path = $var;

        return $this;
    }

    /**
     * Output only. The time when the Aspect 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 Aspect 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 Aspect 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 Aspect 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;
    }

    /**
     * Required. The content of the aspect, according to its aspect type schema.
     * This will replace `content`.
     * The maximum size of the field is 120KB (encoded as UTF-8).
     *
     * Generated from protobuf field <code>.google.protobuf.Struct data = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Protobuf\Struct|null
     */
    public function getData()
    {
        return $this->data;
    }

    public function hasData()
    {
        return isset($this->data);
    }

    public function clearData()
    {
        unset($this->data);
    }

    /**
     * Required. The content of the aspect, according to its aspect type schema.
     * This will replace `content`.
     * The maximum size of the field is 120KB (encoded as UTF-8).
     *
     * Generated from protobuf field <code>.google.protobuf.Struct data = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Protobuf\Struct $var
     * @return $this
     */
    public function setData($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class);
        $this->data = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.AspectSource aspect_source = 9 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return \Google\Cloud\Dataplex\V1\AspectSource|null
     */
    public function getAspectSource()
    {
        return $this->aspect_source;
    }

    public function hasAspectSource()
    {
        return isset($this->aspect_source);
    }

    public function clearAspectSource()
    {
        unset($this->aspect_source);
    }

    /**
     * Generated from protobuf field <code>.google.cloud.dataplex.v1.AspectSource aspect_source = 9 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dataplex\V1\AspectSource $var
     * @return $this
     */
    public function setAspectSource($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dataplex\V1\AspectSource::class);
        $this->aspect_source = $var;

        return $this;
    }

}

