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

namespace PhpWA\Protocol\Proto;

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

/**
 * Generated from protobuf message <code>proto.LegacyMessage</code>
 */
class LegacyMessage extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>optional .proto.Message.EventResponseMessage eventResponseMessage = 1;</code>
     */
    protected $eventResponseMessage = null;
    /**
     * Generated from protobuf field <code>optional .proto.Message.PollVoteMessage pollVote = 2;</code>
     */
    protected $pollVote = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \PhpWA\Protocol\Proto\Message\EventResponseMessage $eventResponseMessage
     *     @type \PhpWA\Protocol\Proto\Message\PollVoteMessage $pollVote
     * }
     */
    public function __construct($data = NULL) {
        \PhpWA\Protocol\Proto\Metadata\WAProto::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>optional .proto.Message.EventResponseMessage eventResponseMessage = 1;</code>
     * @return \PhpWA\Protocol\Proto\Message\EventResponseMessage|null
     */
    public function getEventResponseMessage()
    {
        return $this->eventResponseMessage;
    }

    public function hasEventResponseMessage()
    {
        return isset($this->eventResponseMessage);
    }

    public function clearEventResponseMessage()
    {
        unset($this->eventResponseMessage);
    }

    /**
     * Generated from protobuf field <code>optional .proto.Message.EventResponseMessage eventResponseMessage = 1;</code>
     * @param \PhpWA\Protocol\Proto\Message\EventResponseMessage $var
     * @return $this
     */
    public function setEventResponseMessage($var)
    {
        GPBUtil::checkMessage($var, \PhpWA\Protocol\Proto\Message\EventResponseMessage::class);
        $this->eventResponseMessage = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>optional .proto.Message.PollVoteMessage pollVote = 2;</code>
     * @return \PhpWA\Protocol\Proto\Message\PollVoteMessage|null
     */
    public function getPollVote()
    {
        return $this->pollVote;
    }

    public function hasPollVote()
    {
        return isset($this->pollVote);
    }

    public function clearPollVote()
    {
        unset($this->pollVote);
    }

    /**
     * Generated from protobuf field <code>optional .proto.Message.PollVoteMessage pollVote = 2;</code>
     * @param \PhpWA\Protocol\Proto\Message\PollVoteMessage $var
     * @return $this
     */
    public function setPollVote($var)
    {
        GPBUtil::checkMessage($var, \PhpWA\Protocol\Proto\Message\PollVoteMessage::class);
        $this->pollVote = $var;

        return $this;
    }

}

