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

namespace Livekit;

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

/**
 * PurchasePhoneNumberRequest - Request to purchase phone numbers
 *
 * Generated from protobuf message <code>livekit.PurchasePhoneNumberRequest</code>
 */
class PurchasePhoneNumberRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Phone numbers to purchase (e.g., ["+1234567890", "+1234567891"])
     *
     * Generated from protobuf field <code>repeated string phone_numbers = 1;</code>
     */
    private $phone_numbers;
    /**
     * SIP dispatch rule ID to apply to all purchased numbers
     *
     * Generated from protobuf field <code>optional string sip_dispatch_rule_id = 2 [(.logger.name) = "sipDispatchRuleID"];</code>
     */
    protected $sip_dispatch_rule_id = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string[] $phone_numbers
     *           Phone numbers to purchase (e.g., ["+1234567890", "+1234567891"])
     *     @type string $sip_dispatch_rule_id
     *           SIP dispatch rule ID to apply to all purchased numbers
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\LivekitPhoneNumber::initOnce();
        parent::__construct($data);
    }

    /**
     * Phone numbers to purchase (e.g., ["+1234567890", "+1234567891"])
     *
     * Generated from protobuf field <code>repeated string phone_numbers = 1;</code>
     * @return RepeatedField<string>
     */
    public function getPhoneNumbers()
    {
        return $this->phone_numbers;
    }

    /**
     * Phone numbers to purchase (e.g., ["+1234567890", "+1234567891"])
     *
     * Generated from protobuf field <code>repeated string phone_numbers = 1;</code>
     * @param string[] $var
     * @return $this
     */
    public function setPhoneNumbers($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->phone_numbers = $arr;

        return $this;
    }

    /**
     * SIP dispatch rule ID to apply to all purchased numbers
     *
     * Generated from protobuf field <code>optional string sip_dispatch_rule_id = 2 [(.logger.name) = "sipDispatchRuleID"];</code>
     * @return string
     */
    public function getSipDispatchRuleId()
    {
        return isset($this->sip_dispatch_rule_id) ? $this->sip_dispatch_rule_id : '';
    }

    public function hasSipDispatchRuleId()
    {
        return isset($this->sip_dispatch_rule_id);
    }

    public function clearSipDispatchRuleId()
    {
        unset($this->sip_dispatch_rule_id);
    }

    /**
     * SIP dispatch rule ID to apply to all purchased numbers
     *
     * Generated from protobuf field <code>optional string sip_dispatch_rule_id = 2 [(.logger.name) = "sipDispatchRuleID"];</code>
     * @param string $var
     * @return $this
     */
    public function setSipDispatchRuleId($var)
    {
        GPBUtil::checkString($var, True);
        $this->sip_dispatch_rule_id = $var;

        return $this;
    }

}

