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

namespace Livekit;

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

/**
 * @deprecated
 * Generated from protobuf message <code>livekit.CreateSIPTrunkRequest</code>
 */
class CreateSIPTrunkRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * CIDR or IPs that traffic is accepted from
     * An empty list means all inbound traffic is accepted.
     *
     * Generated from protobuf field <code>repeated string inbound_addresses = 1;</code>
     */
    private $inbound_addresses;
    /**
     * IP that SIP INVITE is sent too
     *
     * Generated from protobuf field <code>string outbound_address = 2;</code>
     */
    protected $outbound_address = '';
    /**
     * Number used to make outbound calls
     *
     * Generated from protobuf field <code>string outbound_number = 3;</code>
     */
    protected $outbound_number = '';
    /**
     * Generated from protobuf field <code>repeated string inbound_numbers_regex = 4 [deprecated = true];</code>
     * @deprecated
     */
    private $inbound_numbers_regex;
    /**
     * Accepted `To` values. This Trunk will only accept a call made to
     * these numbers. This allows you to have distinct Trunks for different phone
     * numbers at the same provider.
     *
     * Generated from protobuf field <code>repeated string inbound_numbers = 9;</code>
     */
    private $inbound_numbers;
    /**
     * Username and password used to authenticate inbound and outbound SIP invites
     * May be empty to have no Authentication
     *
     * Generated from protobuf field <code>string inbound_username = 5 [(.logger.redact) = true];</code>
     */
    protected $inbound_username = '';
    /**
     * Generated from protobuf field <code>string inbound_password = 6 [(.logger.redact) = true];</code>
     */
    protected $inbound_password = '';
    /**
     * Generated from protobuf field <code>string outbound_username = 7 [(.logger.redact) = true];</code>
     */
    protected $outbound_username = '';
    /**
     * Generated from protobuf field <code>string outbound_password = 8 [(.logger.redact) = true];</code>
     */
    protected $outbound_password = '';
    /**
     * Optional human-readable name for the Trunk.
     *
     * Generated from protobuf field <code>string name = 10;</code>
     */
    protected $name = '';
    /**
     * Optional user-defined metadata for the Trunk.
     *
     * Generated from protobuf field <code>string metadata = 11 [(.logger.redact) = true, (.logger.redact_format) = "<redacted ({{ .Size }} bytes)>"];</code>
     */
    protected $metadata = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string[] $inbound_addresses
     *           CIDR or IPs that traffic is accepted from
     *           An empty list means all inbound traffic is accepted.
     *     @type string $outbound_address
     *           IP that SIP INVITE is sent too
     *     @type string $outbound_number
     *           Number used to make outbound calls
     *     @type string[] $inbound_numbers_regex
     *     @type string[] $inbound_numbers
     *           Accepted `To` values. This Trunk will only accept a call made to
     *           these numbers. This allows you to have distinct Trunks for different phone
     *           numbers at the same provider.
     *     @type string $inbound_username
     *           Username and password used to authenticate inbound and outbound SIP invites
     *           May be empty to have no Authentication
     *     @type string $inbound_password
     *     @type string $outbound_username
     *     @type string $outbound_password
     *     @type string $name
     *           Optional human-readable name for the Trunk.
     *     @type string $metadata
     *           Optional user-defined metadata for the Trunk.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\LivekitSip::initOnce();
        parent::__construct($data);
    }

    /**
     * CIDR or IPs that traffic is accepted from
     * An empty list means all inbound traffic is accepted.
     *
     * Generated from protobuf field <code>repeated string inbound_addresses = 1;</code>
     * @return RepeatedField<string>
     */
    public function getInboundAddresses()
    {
        return $this->inbound_addresses;
    }

    /**
     * CIDR or IPs that traffic is accepted from
     * An empty list means all inbound traffic is accepted.
     *
     * Generated from protobuf field <code>repeated string inbound_addresses = 1;</code>
     * @param string[] $var
     * @return $this
     */
    public function setInboundAddresses($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->inbound_addresses = $arr;

        return $this;
    }

    /**
     * IP that SIP INVITE is sent too
     *
     * Generated from protobuf field <code>string outbound_address = 2;</code>
     * @return string
     */
    public function getOutboundAddress()
    {
        return $this->outbound_address;
    }

    /**
     * IP that SIP INVITE is sent too
     *
     * Generated from protobuf field <code>string outbound_address = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setOutboundAddress($var)
    {
        GPBUtil::checkString($var, True);
        $this->outbound_address = $var;

        return $this;
    }

    /**
     * Number used to make outbound calls
     *
     * Generated from protobuf field <code>string outbound_number = 3;</code>
     * @return string
     */
    public function getOutboundNumber()
    {
        return $this->outbound_number;
    }

    /**
     * Number used to make outbound calls
     *
     * Generated from protobuf field <code>string outbound_number = 3;</code>
     * @param string $var
     * @return $this
     */
    public function setOutboundNumber($var)
    {
        GPBUtil::checkString($var, True);
        $this->outbound_number = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated string inbound_numbers_regex = 4 [deprecated = true];</code>
     * @return RepeatedField<string>
     * @deprecated
     */
    public function getInboundNumbersRegex()
    {
        if (count($this->inbound_numbers_regex) !== 0) {
            @trigger_error('inbound_numbers_regex is deprecated.', E_USER_DEPRECATED);
        }
        return $this->inbound_numbers_regex;
    }

    /**
     * Generated from protobuf field <code>repeated string inbound_numbers_regex = 4 [deprecated = true];</code>
     * @param string[] $var
     * @return $this
     * @deprecated
     */
    public function setInboundNumbersRegex($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        if (count($arr) !== 0) {
            @trigger_error('inbound_numbers_regex is deprecated.', E_USER_DEPRECATED);
        }
        $this->inbound_numbers_regex = $arr;

        return $this;
    }

    /**
     * Accepted `To` values. This Trunk will only accept a call made to
     * these numbers. This allows you to have distinct Trunks for different phone
     * numbers at the same provider.
     *
     * Generated from protobuf field <code>repeated string inbound_numbers = 9;</code>
     * @return RepeatedField<string>
     */
    public function getInboundNumbers()
    {
        return $this->inbound_numbers;
    }

    /**
     * Accepted `To` values. This Trunk will only accept a call made to
     * these numbers. This allows you to have distinct Trunks for different phone
     * numbers at the same provider.
     *
     * Generated from protobuf field <code>repeated string inbound_numbers = 9;</code>
     * @param string[] $var
     * @return $this
     */
    public function setInboundNumbers($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->inbound_numbers = $arr;

        return $this;
    }

    /**
     * Username and password used to authenticate inbound and outbound SIP invites
     * May be empty to have no Authentication
     *
     * Generated from protobuf field <code>string inbound_username = 5 [(.logger.redact) = true];</code>
     * @return string
     */
    public function getInboundUsername()
    {
        return $this->inbound_username;
    }

    /**
     * Username and password used to authenticate inbound and outbound SIP invites
     * May be empty to have no Authentication
     *
     * Generated from protobuf field <code>string inbound_username = 5 [(.logger.redact) = true];</code>
     * @param string $var
     * @return $this
     */
    public function setInboundUsername($var)
    {
        GPBUtil::checkString($var, True);
        $this->inbound_username = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string inbound_password = 6 [(.logger.redact) = true];</code>
     * @return string
     */
    public function getInboundPassword()
    {
        return $this->inbound_password;
    }

    /**
     * Generated from protobuf field <code>string inbound_password = 6 [(.logger.redact) = true];</code>
     * @param string $var
     * @return $this
     */
    public function setInboundPassword($var)
    {
        GPBUtil::checkString($var, True);
        $this->inbound_password = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string outbound_username = 7 [(.logger.redact) = true];</code>
     * @return string
     */
    public function getOutboundUsername()
    {
        return $this->outbound_username;
    }

    /**
     * Generated from protobuf field <code>string outbound_username = 7 [(.logger.redact) = true];</code>
     * @param string $var
     * @return $this
     */
    public function setOutboundUsername($var)
    {
        GPBUtil::checkString($var, True);
        $this->outbound_username = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string outbound_password = 8 [(.logger.redact) = true];</code>
     * @return string
     */
    public function getOutboundPassword()
    {
        return $this->outbound_password;
    }

    /**
     * Generated from protobuf field <code>string outbound_password = 8 [(.logger.redact) = true];</code>
     * @param string $var
     * @return $this
     */
    public function setOutboundPassword($var)
    {
        GPBUtil::checkString($var, True);
        $this->outbound_password = $var;

        return $this;
    }

    /**
     * Optional human-readable name for the Trunk.
     *
     * Generated from protobuf field <code>string name = 10;</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Optional human-readable name for the Trunk.
     *
     * Generated from protobuf field <code>string name = 10;</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * Optional user-defined metadata for the Trunk.
     *
     * Generated from protobuf field <code>string metadata = 11 [(.logger.redact) = true, (.logger.redact_format) = "<redacted ({{ .Size }} bytes)>"];</code>
     * @return string
     */
    public function getMetadata()
    {
        return $this->metadata;
    }

    /**
     * Optional user-defined metadata for the Trunk.
     *
     * Generated from protobuf field <code>string metadata = 11 [(.logger.redact) = true, (.logger.redact_format) = "<redacted ({{ .Size }} bytes)>"];</code>
     * @param string $var
     * @return $this
     */
    public function setMetadata($var)
    {
        GPBUtil::checkString($var, True);
        $this->metadata = $var;

        return $this;
    }

}

