|
| 1 | +# coding: utf-8 |
| 2 | +# Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. |
| 3 | + |
| 4 | +from .dhcp_option import DhcpOption |
| 5 | +from ...util import formatted_flat_dict |
| 6 | + |
| 7 | + |
| 8 | +class DhcpSearchDomainOption(DhcpOption): |
| 9 | + |
| 10 | + def __init__(self): |
| 11 | + |
| 12 | + self.swagger_types = { |
| 13 | + 'type': 'str', |
| 14 | + 'search_domain_names': 'list[str]' |
| 15 | + } |
| 16 | + |
| 17 | + self.attribute_map = { |
| 18 | + 'type': 'type', |
| 19 | + 'search_domain_names': 'searchDomainNames' |
| 20 | + } |
| 21 | + |
| 22 | + self._type = None |
| 23 | + self._search_domain_names = None |
| 24 | + self._type = 'SearchDomain' |
| 25 | + |
| 26 | + @property |
| 27 | + def search_domain_names(self): |
| 28 | + """ |
| 29 | + Gets the search_domain_names of this DhcpSearchDomainOption. |
| 30 | + A single search domain name according to `RFC 952`__ |
| 31 | + and `RFC 1123`__. During a DNS query, |
| 32 | + the OS will append this search domain name to the value being queried, but only if |
| 33 | + that value is not a fully qualified domain name (FQDN). |
| 34 | +
|
| 35 | + If you set :class:`DhcpDnsOption` to `VcnLocalPlusInternet`, |
| 36 | + and you assign a DNS label to the VCN during creation, the search domain name in the |
| 37 | + VCN's default set of DHCP options is automatically set to the VCN domain |
| 38 | + (e.g., `vcn1.oraclevcn.com`). |
| 39 | +
|
| 40 | + If you don't want to use a search domain name, omit this option from the |
| 41 | + set of DHCP options. Do not include this option with an empty list |
| 42 | + of search domain names, or with an empty string as the value for any search |
| 43 | + domain name. |
| 44 | +
|
| 45 | + __ https://tools.ietf.org/html/rfc952 |
| 46 | + __ https://tools.ietf.org/html/rfc1123 |
| 47 | +
|
| 48 | +
|
| 49 | + :return: The search_domain_names of this DhcpSearchDomainOption. |
| 50 | + :rtype: list[str] |
| 51 | + """ |
| 52 | + return self._search_domain_names |
| 53 | + |
| 54 | + @search_domain_names.setter |
| 55 | + def search_domain_names(self, search_domain_names): |
| 56 | + """ |
| 57 | + Sets the search_domain_names of this DhcpSearchDomainOption. |
| 58 | + A single search domain name according to `RFC 952`__ |
| 59 | + and `RFC 1123`__. During a DNS query, |
| 60 | + the OS will append this search domain name to the value being queried, but only if |
| 61 | + that value is not a fully qualified domain name (FQDN). |
| 62 | +
|
| 63 | + If you set :class:`DhcpDnsOption` to `VcnLocalPlusInternet`, |
| 64 | + and you assign a DNS label to the VCN during creation, the search domain name in the |
| 65 | + VCN's default set of DHCP options is automatically set to the VCN domain |
| 66 | + (e.g., `vcn1.oraclevcn.com`). |
| 67 | +
|
| 68 | + If you don't want to use a search domain name, omit this option from the |
| 69 | + set of DHCP options. Do not include this option with an empty list |
| 70 | + of search domain names, or with an empty string as the value for any search |
| 71 | + domain name. |
| 72 | +
|
| 73 | + __ https://tools.ietf.org/html/rfc952 |
| 74 | + __ https://tools.ietf.org/html/rfc1123 |
| 75 | +
|
| 76 | +
|
| 77 | + :param search_domain_names: The search_domain_names of this DhcpSearchDomainOption. |
| 78 | + :type: list[str] |
| 79 | + """ |
| 80 | + self._search_domain_names = search_domain_names |
| 81 | + |
| 82 | + def __repr__(self): |
| 83 | + return formatted_flat_dict(self) |
| 84 | + |
| 85 | + def __eq__(self, other): |
| 86 | + if other is None: |
| 87 | + return False |
| 88 | + |
| 89 | + return self.__dict__ == other.__dict__ |
| 90 | + |
| 91 | + def __ne__(self, other): |
| 92 | + return not self == other |
0 commit comments