<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: temporal/api/workflowservice/v1/request_response.proto

namespace Temporal\Api\Workflowservice\V1;

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

/**
 * Generated from protobuf message <code>temporal.api.workflowservice.v1.RegisterNamespaceRequest</code>
 */
class RegisterNamespaceRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string namespace = 1;</code>
     */
    protected $namespace = '';
    /**
     * Generated from protobuf field <code>string description = 2;</code>
     */
    protected $description = '';
    /**
     * Generated from protobuf field <code>string owner_email = 3;</code>
     */
    protected $owner_email = '';
    /**
     * Generated from protobuf field <code>.google.protobuf.Duration workflow_execution_retention_period = 4;</code>
     */
    protected $workflow_execution_retention_period = null;
    /**
     * Generated from protobuf field <code>repeated .temporal.api.replication.v1.ClusterReplicationConfig clusters = 5;</code>
     */
    private $clusters;
    /**
     * Generated from protobuf field <code>string active_cluster_name = 6;</code>
     */
    protected $active_cluster_name = '';
    /**
     * A key-value map for any customized purpose.
     *
     * Generated from protobuf field <code>map<string, string> data = 7;</code>
     */
    private $data;
    /**
     * Generated from protobuf field <code>string security_token = 8;</code>
     */
    protected $security_token = '';
    /**
     * Generated from protobuf field <code>bool is_global_namespace = 9;</code>
     */
    protected $is_global_namespace = false;
    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState history_archival_state = 10;</code>
     */
    protected $history_archival_state = 0;
    /**
     * Generated from protobuf field <code>string history_archival_uri = 11;</code>
     */
    protected $history_archival_uri = '';
    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState visibility_archival_state = 12;</code>
     */
    protected $visibility_archival_state = 0;
    /**
     * Generated from protobuf field <code>string visibility_archival_uri = 13;</code>
     */
    protected $visibility_archival_uri = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $namespace
     *     @type string $description
     *     @type string $owner_email
     *     @type \Google\Protobuf\Duration $workflow_execution_retention_period
     *     @type \Temporal\Api\Replication\V1\ClusterReplicationConfig[] $clusters
     *     @type string $active_cluster_name
     *     @type array|\Google\Protobuf\Internal\MapField $data
     *           A key-value map for any customized purpose.
     *     @type string $security_token
     *     @type bool $is_global_namespace
     *     @type int $history_archival_state
     *           If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *     @type string $history_archival_uri
     *     @type int $visibility_archival_state
     *           If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *     @type string $visibility_archival_uri
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Temporal\Api\Workflowservice\V1\RequestResponse::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>string namespace = 1;</code>
     * @return string
     */
    public function getNamespace()
    {
        return $this->namespace;
    }

    /**
     * Generated from protobuf field <code>string namespace = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setNamespace($var)
    {
        GPBUtil::checkString($var, True);
        $this->namespace = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string description = 2;</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Generated from protobuf field <code>string description = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string owner_email = 3;</code>
     * @return string
     */
    public function getOwnerEmail()
    {
        return $this->owner_email;
    }

    /**
     * Generated from protobuf field <code>string owner_email = 3;</code>
     * @param string $var
     * @return $this
     */
    public function setOwnerEmail($var)
    {
        GPBUtil::checkString($var, True);
        $this->owner_email = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.protobuf.Duration workflow_execution_retention_period = 4;</code>
     * @return \Google\Protobuf\Duration|null
     */
    public function getWorkflowExecutionRetentionPeriod()
    {
        return $this->workflow_execution_retention_period;
    }

    public function hasWorkflowExecutionRetentionPeriod()
    {
        return isset($this->workflow_execution_retention_period);
    }

    public function clearWorkflowExecutionRetentionPeriod()
    {
        unset($this->workflow_execution_retention_period);
    }

    /**
     * Generated from protobuf field <code>.google.protobuf.Duration workflow_execution_retention_period = 4;</code>
     * @param \Google\Protobuf\Duration $var
     * @return $this
     */
    public function setWorkflowExecutionRetentionPeriod($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
        $this->workflow_execution_retention_period = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .temporal.api.replication.v1.ClusterReplicationConfig clusters = 5;</code>
     * @return RepeatedField<\Temporal\Api\Replication\V1\ClusterReplicationConfig>
     */
    public function getClusters()
    {
        return $this->clusters;
    }

    /**
     * Generated from protobuf field <code>repeated .temporal.api.replication.v1.ClusterReplicationConfig clusters = 5;</code>
     * @param \Temporal\Api\Replication\V1\ClusterReplicationConfig[] $var
     * @return $this
     */
    public function setClusters($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Temporal\Api\Replication\V1\ClusterReplicationConfig::class);
        $this->clusters = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string active_cluster_name = 6;</code>
     * @return string
     */
    public function getActiveClusterName()
    {
        return $this->active_cluster_name;
    }

    /**
     * Generated from protobuf field <code>string active_cluster_name = 6;</code>
     * @param string $var
     * @return $this
     */
    public function setActiveClusterName($var)
    {
        GPBUtil::checkString($var, True);
        $this->active_cluster_name = $var;

        return $this;
    }

    /**
     * A key-value map for any customized purpose.
     *
     * Generated from protobuf field <code>map<string, string> data = 7;</code>
     * @return \Google\Protobuf\Internal\MapField
     */
    public function getData()
    {
        return $this->data;
    }

    /**
     * A key-value map for any customized purpose.
     *
     * Generated from protobuf field <code>map<string, string> data = 7;</code>
     * @param array|\Google\Protobuf\Internal\MapField $var
     * @return $this
     */
    public function setData($var)
    {
        $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING);
        $this->data = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string security_token = 8;</code>
     * @return string
     */
    public function getSecurityToken()
    {
        return $this->security_token;
    }

    /**
     * Generated from protobuf field <code>string security_token = 8;</code>
     * @param string $var
     * @return $this
     */
    public function setSecurityToken($var)
    {
        GPBUtil::checkString($var, True);
        $this->security_token = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>bool is_global_namespace = 9;</code>
     * @return bool
     */
    public function getIsGlobalNamespace()
    {
        return $this->is_global_namespace;
    }

    /**
     * Generated from protobuf field <code>bool is_global_namespace = 9;</code>
     * @param bool $var
     * @return $this
     */
    public function setIsGlobalNamespace($var)
    {
        GPBUtil::checkBool($var);
        $this->is_global_namespace = $var;

        return $this;
    }

    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState history_archival_state = 10;</code>
     * @return int
     */
    public function getHistoryArchivalState()
    {
        return $this->history_archival_state;
    }

    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState history_archival_state = 10;</code>
     * @param int $var
     * @return $this
     */
    public function setHistoryArchivalState($var)
    {
        GPBUtil::checkEnum($var, \Temporal\Api\Enums\V1\ArchivalState::class);
        $this->history_archival_state = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string history_archival_uri = 11;</code>
     * @return string
     */
    public function getHistoryArchivalUri()
    {
        return $this->history_archival_uri;
    }

    /**
     * Generated from protobuf field <code>string history_archival_uri = 11;</code>
     * @param string $var
     * @return $this
     */
    public function setHistoryArchivalUri($var)
    {
        GPBUtil::checkString($var, True);
        $this->history_archival_uri = $var;

        return $this;
    }

    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState visibility_archival_state = 12;</code>
     * @return int
     */
    public function getVisibilityArchivalState()
    {
        return $this->visibility_archival_state;
    }

    /**
     * If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used.
     *
     * Generated from protobuf field <code>.temporal.api.enums.v1.ArchivalState visibility_archival_state = 12;</code>
     * @param int $var
     * @return $this
     */
    public function setVisibilityArchivalState($var)
    {
        GPBUtil::checkEnum($var, \Temporal\Api\Enums\V1\ArchivalState::class);
        $this->visibility_archival_state = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string visibility_archival_uri = 13;</code>
     * @return string
     */
    public function getVisibilityArchivalUri()
    {
        return $this->visibility_archival_uri;
    }

    /**
     * Generated from protobuf field <code>string visibility_archival_uri = 13;</code>
     * @param string $var
     * @return $this
     */
    public function setVisibilityArchivalUri($var)
    {
        GPBUtil::checkString($var, True);
        $this->visibility_archival_uri = $var;

        return $this;
    }

}

