<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/dialogflow/v2/conversation.proto

namespace Google\Cloud\Dialogflow\V2\Conversation;

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

/**
 * The information about phone calls connected via phone gateway to the
 * conversation.
 *
 * Generated from protobuf message <code>google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo</code>
 */
class TelephonyConnectionInfo extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The number dialed to connect this call in E.164 format.
     *
     * Generated from protobuf field <code>string dialed_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $dialed_number = '';
    /**
     * Optional. SDP of the call. It's initially the SDP answer to the endpoint,
     * but maybe later updated for the purpose of making the link active, etc.
     *
     * Generated from protobuf field <code>string sdp = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $sdp = '';
    /**
     * Output only. The SIP headers from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.SipHeader sip_headers = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $sip_headers;
    /**
     * Output only. The mime content from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.MimeContent extra_mime_contents = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $extra_mime_contents;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $dialed_number
     *           Output only. The number dialed to connect this call in E.164 format.
     *     @type string $sdp
     *           Optional. SDP of the call. It's initially the SDP answer to the endpoint,
     *           but maybe later updated for the purpose of making the link active, etc.
     *     @type array<\Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\SipHeader>|\Google\Protobuf\Internal\RepeatedField $sip_headers
     *           Output only. The SIP headers from the initial SIP INVITE.
     *     @type array<\Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\MimeContent>|\Google\Protobuf\Internal\RepeatedField $extra_mime_contents
     *           Output only. The mime content from the initial SIP INVITE.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dialogflow\V2\Conversation::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The number dialed to connect this call in E.164 format.
     *
     * Generated from protobuf field <code>string dialed_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getDialedNumber()
    {
        return $this->dialed_number;
    }

    /**
     * Output only. The number dialed to connect this call in E.164 format.
     *
     * Generated from protobuf field <code>string dialed_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setDialedNumber($var)
    {
        GPBUtil::checkString($var, True);
        $this->dialed_number = $var;

        return $this;
    }

    /**
     * Optional. SDP of the call. It's initially the SDP answer to the endpoint,
     * but maybe later updated for the purpose of making the link active, etc.
     *
     * Generated from protobuf field <code>string sdp = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getSdp()
    {
        return $this->sdp;
    }

    /**
     * Optional. SDP of the call. It's initially the SDP answer to the endpoint,
     * but maybe later updated for the purpose of making the link active, etc.
     *
     * Generated from protobuf field <code>string sdp = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setSdp($var)
    {
        GPBUtil::checkString($var, True);
        $this->sdp = $var;

        return $this;
    }

    /**
     * Output only. The SIP headers from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.SipHeader sip_headers = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getSipHeaders()
    {
        return $this->sip_headers;
    }

    /**
     * Output only. The SIP headers from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.SipHeader sip_headers = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param array<\Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\SipHeader>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setSipHeaders($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\SipHeader::class);
        $this->sip_headers = $arr;

        return $this;
    }

    /**
     * Output only. The mime content from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.MimeContent extra_mime_contents = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getExtraMimeContents()
    {
        return $this->extra_mime_contents;
    }

    /**
     * Output only. The mime content from the initial SIP INVITE.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.Conversation.TelephonyConnectionInfo.MimeContent extra_mime_contents = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param array<\Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\MimeContent>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setExtraMimeContents($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dialogflow\V2\Conversation\TelephonyConnectionInfo\MimeContent::class);
        $this->extra_mime_contents = $arr;

        return $this;
    }

}


