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

namespace RoadRunner\Websockets\DTO\V1;

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

/**
 * RPC request with messages
 *
 * Generated from protobuf message <code>websockets.v1.Request</code>
 */
class Request extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>repeated .websockets.v1.Message messages = 1;</code>
     */
    private $messages;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \RoadRunner\Websockets\DTO\V1\Message[] $messages
     * }
     */
    public function __construct($data = NULL) {
        \RoadRunner\Websockets\DTO\V1\GPBMetadata\Websockets::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>repeated .websockets.v1.Message messages = 1;</code>
     * @return RepeatedField<\RoadRunner\Websockets\DTO\V1\Message>
     */
    public function getMessages()
    {
        return $this->messages;
    }

    /**
     * Generated from protobuf field <code>repeated .websockets.v1.Message messages = 1;</code>
     * @param \RoadRunner\Websockets\DTO\V1\Message[] $var
     * @return $this
     */
    public function setMessages($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \RoadRunner\Websockets\DTO\V1\Message::class);
        $this->messages = $arr;

        return $this;
    }

}

