<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: temporal/api/operatorservice/v1/request_response.proto

namespace Temporal\Api\Operatorservice\V1;

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

/**
 * Generated from protobuf message <code>temporal.api.operatorservice.v1.CreateNexusOutgoingServiceRequest</code>
 */
class CreateNexusOutgoingServiceRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Namespace to create this service definition in.
     *
     * Generated from protobuf field <code>string namespace = 1;</code>
     */
    protected $namespace = '';
    /**
     * Name of service to create.
     *
     * Generated from protobuf field <code>string name = 2;</code>
     */
    protected $name = '';
    /**
     * Service definition to create. Does not contain a version because there's nothing to match against.
     *
     * Generated from protobuf field <code>.temporal.api.nexus.v1.OutgoingServiceSpec spec = 3;</code>
     */
    protected $spec = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $namespace
     *           Namespace to create this service definition in.
     *     @type string $name
     *           Name of service to create.
     *     @type \Temporal\Api\Nexus\V1\OutgoingServiceSpec $spec
     *           Service definition to create. Does not contain a version because there's nothing to match against.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Temporal\Api\Operatorservice\V1\RequestResponse::initOnce();
        parent::__construct($data);
    }

    /**
     * Namespace to create this service definition in.
     *
     * Generated from protobuf field <code>string namespace = 1;</code>
     * @return string
     */
    public function getNamespace()
    {
        return $this->namespace;
    }

    /**
     * Namespace to create this service definition in.
     *
     * 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;
    }

    /**
     * Name of service to create.
     *
     * Generated from protobuf field <code>string name = 2;</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Name of service to create.
     *
     * Generated from protobuf field <code>string name = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * Service definition to create. Does not contain a version because there's nothing to match against.
     *
     * Generated from protobuf field <code>.temporal.api.nexus.v1.OutgoingServiceSpec spec = 3;</code>
     * @return \Temporal\Api\Nexus\V1\OutgoingServiceSpec|null
     */
    public function getSpec()
    {
        return $this->spec;
    }

    public function hasSpec()
    {
        return isset($this->spec);
    }

    public function clearSpec()
    {
        unset($this->spec);
    }

    /**
     * Service definition to create. Does not contain a version because there's nothing to match against.
     *
     * Generated from protobuf field <code>.temporal.api.nexus.v1.OutgoingServiceSpec spec = 3;</code>
     * @param \Temporal\Api\Nexus\V1\OutgoingServiceSpec $var
     * @return $this
     */
    public function setSpec($var)
    {
        GPBUtil::checkMessage($var, \Temporal\Api\Nexus\V1\OutgoingServiceSpec::class);
        $this->spec = $var;

        return $this;
    }

}

