<?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.CreateWorkflowRuleResponse</code>
 */
class CreateWorkflowRuleResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * Created rule.
     *
     * Generated from protobuf field <code>.temporal.api.rules.v1.WorkflowRule rule = 1;</code>
     */
    protected $rule = null;
    /**
     * Batch Job ID if force-scan flag was provided. Otherwise empty.
     *
     * Generated from protobuf field <code>string job_id = 2;</code>
     */
    protected $job_id = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Temporal\Api\Rules\V1\WorkflowRule $rule
     *           Created rule.
     *     @type string $job_id
     *           Batch Job ID if force-scan flag was provided. Otherwise empty.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Temporal\Api\Workflowservice\V1\RequestResponse::initOnce();
        parent::__construct($data);
    }

    /**
     * Created rule.
     *
     * Generated from protobuf field <code>.temporal.api.rules.v1.WorkflowRule rule = 1;</code>
     * @return \Temporal\Api\Rules\V1\WorkflowRule|null
     */
    public function getRule()
    {
        return $this->rule;
    }

    public function hasRule()
    {
        return isset($this->rule);
    }

    public function clearRule()
    {
        unset($this->rule);
    }

    /**
     * Created rule.
     *
     * Generated from protobuf field <code>.temporal.api.rules.v1.WorkflowRule rule = 1;</code>
     * @param \Temporal\Api\Rules\V1\WorkflowRule $var
     * @return $this
     */
    public function setRule($var)
    {
        GPBUtil::checkMessage($var, \Temporal\Api\Rules\V1\WorkflowRule::class);
        $this->rule = $var;

        return $this;
    }

    /**
     * Batch Job ID if force-scan flag was provided. Otherwise empty.
     *
     * Generated from protobuf field <code>string job_id = 2;</code>
     * @return string
     */
    public function getJobId()
    {
        return $this->job_id;
    }

    /**
     * Batch Job ID if force-scan flag was provided. Otherwise empty.
     *
     * Generated from protobuf field <code>string job_id = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setJobId($var)
    {
        GPBUtil::checkString($var, True);
        $this->job_id = $var;

        return $this;
    }

}

