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

namespace Temporal\Api\History\V1;

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

/**
 * Generated from protobuf message <code>temporal.api.history.v1.WorkflowTaskTimedOutEventAttributes</code>
 */
class WorkflowTaskTimedOutEventAttributes extends \Google\Protobuf\Internal\Message
{
    /**
     * The id of the `WORKFLOW_TASK_SCHEDULED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 scheduled_event_id = 1;</code>
     */
    protected $scheduled_event_id = 0;
    /**
     * The id of the `WORKFLOW_TASK_STARTED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 started_event_id = 2;</code>
     */
    protected $started_event_id = 0;
    /**
     * Generated from protobuf field <code>.temporal.api.enums.v1.TimeoutType timeout_type = 3;</code>
     */
    protected $timeout_type = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int|string $scheduled_event_id
     *           The id of the `WORKFLOW_TASK_SCHEDULED` event this task corresponds to
     *     @type int|string $started_event_id
     *           The id of the `WORKFLOW_TASK_STARTED` event this task corresponds to
     *     @type int $timeout_type
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Temporal\Api\History\V1\Message::initOnce();
        parent::__construct($data);
    }

    /**
     * The id of the `WORKFLOW_TASK_SCHEDULED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 scheduled_event_id = 1;</code>
     * @return int|string
     */
    public function getScheduledEventId()
    {
        return $this->scheduled_event_id;
    }

    /**
     * The id of the `WORKFLOW_TASK_SCHEDULED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 scheduled_event_id = 1;</code>
     * @param int|string $var
     * @return $this
     */
    public function setScheduledEventId($var)
    {
        GPBUtil::checkInt64($var);
        $this->scheduled_event_id = $var;

        return $this;
    }

    /**
     * The id of the `WORKFLOW_TASK_STARTED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 started_event_id = 2;</code>
     * @return int|string
     */
    public function getStartedEventId()
    {
        return $this->started_event_id;
    }

    /**
     * The id of the `WORKFLOW_TASK_STARTED` event this task corresponds to
     *
     * Generated from protobuf field <code>int64 started_event_id = 2;</code>
     * @param int|string $var
     * @return $this
     */
    public function setStartedEventId($var)
    {
        GPBUtil::checkInt64($var);
        $this->started_event_id = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>.temporal.api.enums.v1.TimeoutType timeout_type = 3;</code>
     * @return int
     */
    public function getTimeoutType()
    {
        return $this->timeout_type;
    }

    /**
     * Generated from protobuf field <code>.temporal.api.enums.v1.TimeoutType timeout_type = 3;</code>
     * @param int $var
     * @return $this
     */
    public function setTimeoutType($var)
    {
        GPBUtil::checkEnum($var, \Temporal\Api\Enums\V1\TimeoutType::class);
        $this->timeout_type = $var;

        return $this;
    }

}

