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

namespace Livekit;

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

/**
 * Generated from protobuf message <code>livekit.ConnectWhatsAppCallRequest</code>
 */
class ConnectWhatsAppCallRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Required - Call ID sent by Meta
     *
     * Generated from protobuf field <code>string whatsapp_call_id = 1;</code>
     */
    protected $whatsapp_call_id = '';
    /**
     * Required - The call connect webhook comes with SDP from Meta
     * It is the answer SDP for a business initiated call
     *
     * Generated from protobuf field <code>.livekit.SessionDescription sdp = 2;</code>
     */
    protected $sdp = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $whatsapp_call_id
     *           Required - Call ID sent by Meta
     *     @type \Livekit\SessionDescription $sdp
     *           Required - The call connect webhook comes with SDP from Meta
     *           It is the answer SDP for a business initiated call
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\LivekitConnectorWhatsapp::initOnce();
        parent::__construct($data);
    }

    /**
     * Required - Call ID sent by Meta
     *
     * Generated from protobuf field <code>string whatsapp_call_id = 1;</code>
     * @return string
     */
    public function getWhatsappCallId()
    {
        return $this->whatsapp_call_id;
    }

    /**
     * Required - Call ID sent by Meta
     *
     * Generated from protobuf field <code>string whatsapp_call_id = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setWhatsappCallId($var)
    {
        GPBUtil::checkString($var, True);
        $this->whatsapp_call_id = $var;

        return $this;
    }

    /**
     * Required - The call connect webhook comes with SDP from Meta
     * It is the answer SDP for a business initiated call
     *
     * Generated from protobuf field <code>.livekit.SessionDescription sdp = 2;</code>
     * @return \Livekit\SessionDescription|null
     */
    public function getSdp()
    {
        return $this->sdp;
    }

    public function hasSdp()
    {
        return isset($this->sdp);
    }

    public function clearSdp()
    {
        unset($this->sdp);
    }

    /**
     * Required - The call connect webhook comes with SDP from Meta
     * It is the answer SDP for a business initiated call
     *
     * Generated from protobuf field <code>.livekit.SessionDescription sdp = 2;</code>
     * @param \Livekit\SessionDescription $var
     * @return $this
     */
    public function setSdp($var)
    {
        GPBUtil::checkMessage($var, \Livekit\SessionDescription::class);
        $this->sdp = $var;

        return $this;
    }

}

