<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: plugnmeet_polls.proto

namespace Mynaparrot\PlugnmeetProto;

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

/**
 * Generated from protobuf message <code>plugnmeet.PollInfo</code>
 */
class PollInfo extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string id = 1;</code>
     */
    protected $id = '';
    /**
     * Generated from protobuf field <code>string room_id = 2;</code>
     */
    protected $room_id = '';
    /**
     * Generated from protobuf field <code>string question = 3;</code>
     */
    protected $question = '';
    /**
     * Generated from protobuf field <code>repeated .plugnmeet.CreatePollOptions options = 4;</code>
     */
    private $options;
    /**
     * Generated from protobuf field <code>bool is_running = 5;</code>
     */
    protected $is_running = false;
    /**
     * Generated from protobuf field <code>int64 created = 6;</code>
     */
    protected $created = 0;
    /**
     * Generated from protobuf field <code>string created_by = 7;</code>
     */
    protected $created_by = '';
    /**
     * Generated from protobuf field <code>string closed_by = 8;</code>
     */
    protected $closed_by = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $id
     *     @type string $room_id
     *     @type string $question
     *     @type \Mynaparrot\PlugnmeetProto\CreatePollOptions[] $options
     *     @type bool $is_running
     *     @type int|string $created
     *     @type string $created_by
     *     @type string $closed_by
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\PlugnmeetPolls::initOnce();
        parent::__construct($data);
    }

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

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

        return $this;
    }

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

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

        return $this;
    }

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

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .plugnmeet.CreatePollOptions options = 4;</code>
     * @return RepeatedField<\Mynaparrot\PlugnmeetProto\CreatePollOptions>
     */
    public function getOptions()
    {
        return $this->options;
    }

    /**
     * Generated from protobuf field <code>repeated .plugnmeet.CreatePollOptions options = 4;</code>
     * @param \Mynaparrot\PlugnmeetProto\CreatePollOptions[] $var
     * @return $this
     */
    public function setOptions($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Mynaparrot\PlugnmeetProto\CreatePollOptions::class);
        $this->options = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>bool is_running = 5;</code>
     * @return bool
     */
    public function getIsRunning()
    {
        return $this->is_running;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>int64 created = 6;</code>
     * @return int|string
     */
    public function getCreated()
    {
        return $this->created;
    }

    /**
     * Generated from protobuf field <code>int64 created = 6;</code>
     * @param int|string $var
     * @return $this
     */
    public function setCreated($var)
    {
        GPBUtil::checkInt64($var);
        $this->created = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string created_by = 7;</code>
     * @return string
     */
    public function getCreatedBy()
    {
        return $this->created_by;
    }

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

        return $this;
    }

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

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

        return $this;
    }

}

