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

namespace Google\Cloud\Domains\V1alpha2\DnsSettings;

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

/**
 * Configuration for an arbitrary DNS provider.
 *
 * Generated from protobuf message <code>google.cloud.domains.v1alpha2.DnsSettings.CustomDns</code>
 */
class CustomDns extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. A list of name servers that store the DNS zone for this domain. Each name
     * server is a domain name, with Unicode domain names expressed in
     * Punycode format.
     *
     * Generated from protobuf field <code>repeated string name_servers = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $name_servers;
    /**
     * The list of DS records for this domain, which are used to enable DNSSEC.
     * The domain's DNS provider can provide the values to set here. If this
     * field is empty, DNSSEC is disabled.
     *
     * Generated from protobuf field <code>repeated .google.cloud.domains.v1alpha2.DnsSettings.DsRecord ds_records = 2;</code>
     */
    private $ds_records;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $name_servers
     *           Required. A list of name servers that store the DNS zone for this domain. Each name
     *           server is a domain name, with Unicode domain names expressed in
     *           Punycode format.
     *     @type array<\Google\Cloud\Domains\V1alpha2\DnsSettings\DsRecord>|\Google\Protobuf\Internal\RepeatedField $ds_records
     *           The list of DS records for this domain, which are used to enable DNSSEC.
     *           The domain's DNS provider can provide the values to set here. If this
     *           field is empty, DNSSEC is disabled.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Domains\V1Alpha2\Domains::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. A list of name servers that store the DNS zone for this domain. Each name
     * server is a domain name, with Unicode domain names expressed in
     * Punycode format.
     *
     * Generated from protobuf field <code>repeated string name_servers = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getNameServers()
    {
        return $this->name_servers;
    }

    /**
     * Required. A list of name servers that store the DNS zone for this domain. Each name
     * server is a domain name, with Unicode domain names expressed in
     * Punycode format.
     *
     * Generated from protobuf field <code>repeated string name_servers = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setNameServers($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->name_servers = $arr;

        return $this;
    }

    /**
     * The list of DS records for this domain, which are used to enable DNSSEC.
     * The domain's DNS provider can provide the values to set here. If this
     * field is empty, DNSSEC is disabled.
     *
     * Generated from protobuf field <code>repeated .google.cloud.domains.v1alpha2.DnsSettings.DsRecord ds_records = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getDsRecords()
    {
        return $this->ds_records;
    }

    /**
     * The list of DS records for this domain, which are used to enable DNSSEC.
     * The domain's DNS provider can provide the values to set here. If this
     * field is empty, DNSSEC is disabled.
     *
     * Generated from protobuf field <code>repeated .google.cloud.domains.v1alpha2.DnsSettings.DsRecord ds_records = 2;</code>
     * @param array<\Google\Cloud\Domains\V1alpha2\DnsSettings\DsRecord>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setDsRecords($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Domains\V1alpha2\DnsSettings\DsRecord::class);
        $this->ds_records = $arr;

        return $this;
    }

}


