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

namespace Livekit;

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

/**
 * Generated from protobuf message <code>livekit.UpdateSubscription</code>
 */
class UpdateSubscription extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>repeated string track_sids = 1;</code>
     */
    private $track_sids;
    /**
     * Generated from protobuf field <code>bool subscribe = 2;</code>
     */
    protected $subscribe = false;
    /**
     * Generated from protobuf field <code>repeated .livekit.ParticipantTracks participant_tracks = 3;</code>
     */
    private $participant_tracks;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string[] $track_sids
     *     @type bool $subscribe
     *     @type \Livekit\ParticipantTracks[] $participant_tracks
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\LivekitRtc::initOnce();
        parent::__construct($data);
    }

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

    /**
     * Generated from protobuf field <code>repeated string track_sids = 1;</code>
     * @param string[] $var
     * @return $this
     */
    public function setTrackSids($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->track_sids = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>bool subscribe = 2;</code>
     * @return bool
     */
    public function getSubscribe()
    {
        return $this->subscribe;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .livekit.ParticipantTracks participant_tracks = 3;</code>
     * @return RepeatedField<\Livekit\ParticipantTracks>
     */
    public function getParticipantTracks()
    {
        return $this->participant_tracks;
    }

    /**
     * Generated from protobuf field <code>repeated .livekit.ParticipantTracks participant_tracks = 3;</code>
     * @param \Livekit\ParticipantTracks[] $var
     * @return $this
     */
    public function setParticipantTracks($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Livekit\ParticipantTracks::class);
        $this->participant_tracks = $arr;

        return $this;
    }

}

