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

namespace Rv\Data;

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

/**
 * Generated from protobuf message <code>rv.data.API_v1_Link_Request</code>
 */
class API_v1_Link_Request extends \Google\Protobuf\Internal\Message
{
    protected $Request;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Rv\Data\API_v1_Link_Request\Heartbeat $heartbeat
     *     @type \Rv\Data\API_v1_Link_Request\Status $status
     *     @type \Rv\Data\API_v1_Link_Request\AddMember $add_member
     *     @type \Rv\Data\API_v1_Link_Request\RemoveMember $remove_member
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\ProApiV1Link::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.Heartbeat heartbeat = 1;</code>
     * @return \Rv\Data\API_v1_Link_Request\Heartbeat|null
     */
    public function getHeartbeat()
    {
        return $this->readOneof(1);
    }

    public function hasHeartbeat()
    {
        return $this->hasOneof(1);
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.Heartbeat heartbeat = 1;</code>
     * @param \Rv\Data\API_v1_Link_Request\Heartbeat $var
     * @return $this
     */
    public function setHeartbeat($var)
    {
        GPBUtil::checkMessage($var, \Rv\Data\API_v1_Link_Request\Heartbeat::class);
        $this->writeOneof(1, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.Status status = 2;</code>
     * @return \Rv\Data\API_v1_Link_Request\Status|null
     */
    public function getStatus()
    {
        return $this->readOneof(2);
    }

    public function hasStatus()
    {
        return $this->hasOneof(2);
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.Status status = 2;</code>
     * @param \Rv\Data\API_v1_Link_Request\Status $var
     * @return $this
     */
    public function setStatus($var)
    {
        GPBUtil::checkMessage($var, \Rv\Data\API_v1_Link_Request\Status::class);
        $this->writeOneof(2, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.AddMember add_member = 3;</code>
     * @return \Rv\Data\API_v1_Link_Request\AddMember|null
     */
    public function getAddMember()
    {
        return $this->readOneof(3);
    }

    public function hasAddMember()
    {
        return $this->hasOneof(3);
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.AddMember add_member = 3;</code>
     * @param \Rv\Data\API_v1_Link_Request\AddMember $var
     * @return $this
     */
    public function setAddMember($var)
    {
        GPBUtil::checkMessage($var, \Rv\Data\API_v1_Link_Request\AddMember::class);
        $this->writeOneof(3, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.RemoveMember remove_member = 4;</code>
     * @return \Rv\Data\API_v1_Link_Request\RemoveMember|null
     */
    public function getRemoveMember()
    {
        return $this->readOneof(4);
    }

    public function hasRemoveMember()
    {
        return $this->hasOneof(4);
    }

    /**
     * Generated from protobuf field <code>.rv.data.API_v1_Link_Request.RemoveMember remove_member = 4;</code>
     * @param \Rv\Data\API_v1_Link_Request\RemoveMember $var
     * @return $this
     */
    public function setRemoveMember($var)
    {
        GPBUtil::checkMessage($var, \Rv\Data\API_v1_Link_Request\RemoveMember::class);
        $this->writeOneof(4, $var);

        return $this;
    }

    /**
     * @return string
     */
    public function getRequest()
    {
        return $this->whichOneof("Request");
    }

}

