1# coding: utf-8
2# Copyright (c) 2016, 2021, Oracle and/or its affiliates.  All rights reserved.
3# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
4
5
6from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel  # noqa: F401
7from oci.decorators import init_model_state_from_kwargs
8
9
10@init_model_state_from_kwargs
11class CreateCloudAutonomousVmClusterDetails(object):
12    """
13    Details for the create cloud Autonomous VM cluster operation.
14    """
15
16    #: A constant which can be used with the license_model property of a CreateCloudAutonomousVmClusterDetails.
17    #: This constant has a value of "LICENSE_INCLUDED"
18    LICENSE_MODEL_LICENSE_INCLUDED = "LICENSE_INCLUDED"
19
20    #: A constant which can be used with the license_model property of a CreateCloudAutonomousVmClusterDetails.
21    #: This constant has a value of "BRING_YOUR_OWN_LICENSE"
22    LICENSE_MODEL_BRING_YOUR_OWN_LICENSE = "BRING_YOUR_OWN_LICENSE"
23
24    def __init__(self, **kwargs):
25        """
26        Initializes a new CreateCloudAutonomousVmClusterDetails object with values from keyword arguments.
27        The following keyword arguments are supported (corresponding to the getters/setters of this class):
28
29        :param compartment_id:
30            The value to assign to the compartment_id property of this CreateCloudAutonomousVmClusterDetails.
31        :type compartment_id: str
32
33        :param description:
34            The value to assign to the description property of this CreateCloudAutonomousVmClusterDetails.
35        :type description: str
36
37        :param subnet_id:
38            The value to assign to the subnet_id property of this CreateCloudAutonomousVmClusterDetails.
39        :type subnet_id: str
40
41        :param display_name:
42            The value to assign to the display_name property of this CreateCloudAutonomousVmClusterDetails.
43        :type display_name: str
44
45        :param cloud_exadata_infrastructure_id:
46            The value to assign to the cloud_exadata_infrastructure_id property of this CreateCloudAutonomousVmClusterDetails.
47        :type cloud_exadata_infrastructure_id: str
48
49        :param license_model:
50            The value to assign to the license_model property of this CreateCloudAutonomousVmClusterDetails.
51            Allowed values for this property are: "LICENSE_INCLUDED", "BRING_YOUR_OWN_LICENSE"
52        :type license_model: str
53
54        :param nsg_ids:
55            The value to assign to the nsg_ids property of this CreateCloudAutonomousVmClusterDetails.
56        :type nsg_ids: list[str]
57
58        :param freeform_tags:
59            The value to assign to the freeform_tags property of this CreateCloudAutonomousVmClusterDetails.
60        :type freeform_tags: dict(str, str)
61
62        :param defined_tags:
63            The value to assign to the defined_tags property of this CreateCloudAutonomousVmClusterDetails.
64        :type defined_tags: dict(str, dict(str, object))
65
66        """
67        self.swagger_types = {
68            'compartment_id': 'str',
69            'description': 'str',
70            'subnet_id': 'str',
71            'display_name': 'str',
72            'cloud_exadata_infrastructure_id': 'str',
73            'license_model': 'str',
74            'nsg_ids': 'list[str]',
75            'freeform_tags': 'dict(str, str)',
76            'defined_tags': 'dict(str, dict(str, object))'
77        }
78
79        self.attribute_map = {
80            'compartment_id': 'compartmentId',
81            'description': 'description',
82            'subnet_id': 'subnetId',
83            'display_name': 'displayName',
84            'cloud_exadata_infrastructure_id': 'cloudExadataInfrastructureId',
85            'license_model': 'licenseModel',
86            'nsg_ids': 'nsgIds',
87            'freeform_tags': 'freeformTags',
88            'defined_tags': 'definedTags'
89        }
90
91        self._compartment_id = None
92        self._description = None
93        self._subnet_id = None
94        self._display_name = None
95        self._cloud_exadata_infrastructure_id = None
96        self._license_model = None
97        self._nsg_ids = None
98        self._freeform_tags = None
99        self._defined_tags = None
100
101    @property
102    def compartment_id(self):
103        """
104        **[Required]** Gets the compartment_id of this CreateCloudAutonomousVmClusterDetails.
105        The `OCID`__ of the compartment.
106
107        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
108
109
110        :return: The compartment_id of this CreateCloudAutonomousVmClusterDetails.
111        :rtype: str
112        """
113        return self._compartment_id
114
115    @compartment_id.setter
116    def compartment_id(self, compartment_id):
117        """
118        Sets the compartment_id of this CreateCloudAutonomousVmClusterDetails.
119        The `OCID`__ of the compartment.
120
121        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
122
123
124        :param compartment_id: The compartment_id of this CreateCloudAutonomousVmClusterDetails.
125        :type: str
126        """
127        self._compartment_id = compartment_id
128
129    @property
130    def description(self):
131        """
132        Gets the description of this CreateCloudAutonomousVmClusterDetails.
133        User defined description of the cloud Autonomous VM cluster.
134
135
136        :return: The description of this CreateCloudAutonomousVmClusterDetails.
137        :rtype: str
138        """
139        return self._description
140
141    @description.setter
142    def description(self, description):
143        """
144        Sets the description of this CreateCloudAutonomousVmClusterDetails.
145        User defined description of the cloud Autonomous VM cluster.
146
147
148        :param description: The description of this CreateCloudAutonomousVmClusterDetails.
149        :type: str
150        """
151        self._description = description
152
153    @property
154    def subnet_id(self):
155        """
156        **[Required]** Gets the subnet_id of this CreateCloudAutonomousVmClusterDetails.
157        The `OCID`__ of the subnet the cloud Autonomous VM Cluster is associated with.
158
159        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
160
161
162        :return: The subnet_id of this CreateCloudAutonomousVmClusterDetails.
163        :rtype: str
164        """
165        return self._subnet_id
166
167    @subnet_id.setter
168    def subnet_id(self, subnet_id):
169        """
170        Sets the subnet_id of this CreateCloudAutonomousVmClusterDetails.
171        The `OCID`__ of the subnet the cloud Autonomous VM Cluster is associated with.
172
173        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
174
175
176        :param subnet_id: The subnet_id of this CreateCloudAutonomousVmClusterDetails.
177        :type: str
178        """
179        self._subnet_id = subnet_id
180
181    @property
182    def display_name(self):
183        """
184        **[Required]** Gets the display_name of this CreateCloudAutonomousVmClusterDetails.
185        The user-friendly name for the cloud Autonomous VM cluster. The name does not need to be unique.
186
187
188        :return: The display_name of this CreateCloudAutonomousVmClusterDetails.
189        :rtype: str
190        """
191        return self._display_name
192
193    @display_name.setter
194    def display_name(self, display_name):
195        """
196        Sets the display_name of this CreateCloudAutonomousVmClusterDetails.
197        The user-friendly name for the cloud Autonomous VM cluster. The name does not need to be unique.
198
199
200        :param display_name: The display_name of this CreateCloudAutonomousVmClusterDetails.
201        :type: str
202        """
203        self._display_name = display_name
204
205    @property
206    def cloud_exadata_infrastructure_id(self):
207        """
208        **[Required]** Gets the cloud_exadata_infrastructure_id of this CreateCloudAutonomousVmClusterDetails.
209        The `OCID`__ of the cloud Exadata infrastructure.
210
211        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
212
213
214        :return: The cloud_exadata_infrastructure_id of this CreateCloudAutonomousVmClusterDetails.
215        :rtype: str
216        """
217        return self._cloud_exadata_infrastructure_id
218
219    @cloud_exadata_infrastructure_id.setter
220    def cloud_exadata_infrastructure_id(self, cloud_exadata_infrastructure_id):
221        """
222        Sets the cloud_exadata_infrastructure_id of this CreateCloudAutonomousVmClusterDetails.
223        The `OCID`__ of the cloud Exadata infrastructure.
224
225        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
226
227
228        :param cloud_exadata_infrastructure_id: The cloud_exadata_infrastructure_id of this CreateCloudAutonomousVmClusterDetails.
229        :type: str
230        """
231        self._cloud_exadata_infrastructure_id = cloud_exadata_infrastructure_id
232
233    @property
234    def license_model(self):
235        """
236        Gets the license_model of this CreateCloudAutonomousVmClusterDetails.
237        The Oracle license model that applies to the Oracle Autonomous Database. Bring your own license (BYOL) allows you to apply your current on-premises Oracle software licenses to equivalent, highly automated Oracle PaaS and IaaS services in the cloud.
238        License Included allows you to subscribe to new Oracle Database software licenses and the Database service.
239        Note that when provisioning an Autonomous Database on `dedicated Exadata infrastructure`__, this attribute must be null because the attribute is already set at the
240        Autonomous Exadata Infrastructure level. When using `shared Exadata infrastructure`__, if a value is not specified, the system will supply the value of `BRING_YOUR_OWN_LICENSE`.
241
242        __ https://docs.cloud.oracle.com/Content/Database/Concepts/adbddoverview.htm
243        __ https://docs.cloud.oracle.com/Content/Database/Concepts/adboverview.htm#AEI
244
245        Allowed values for this property are: "LICENSE_INCLUDED", "BRING_YOUR_OWN_LICENSE"
246
247
248        :return: The license_model of this CreateCloudAutonomousVmClusterDetails.
249        :rtype: str
250        """
251        return self._license_model
252
253    @license_model.setter
254    def license_model(self, license_model):
255        """
256        Sets the license_model of this CreateCloudAutonomousVmClusterDetails.
257        The Oracle license model that applies to the Oracle Autonomous Database. Bring your own license (BYOL) allows you to apply your current on-premises Oracle software licenses to equivalent, highly automated Oracle PaaS and IaaS services in the cloud.
258        License Included allows you to subscribe to new Oracle Database software licenses and the Database service.
259        Note that when provisioning an Autonomous Database on `dedicated Exadata infrastructure`__, this attribute must be null because the attribute is already set at the
260        Autonomous Exadata Infrastructure level. When using `shared Exadata infrastructure`__, if a value is not specified, the system will supply the value of `BRING_YOUR_OWN_LICENSE`.
261
262        __ https://docs.cloud.oracle.com/Content/Database/Concepts/adbddoverview.htm
263        __ https://docs.cloud.oracle.com/Content/Database/Concepts/adboverview.htm#AEI
264
265
266        :param license_model: The license_model of this CreateCloudAutonomousVmClusterDetails.
267        :type: str
268        """
269        allowed_values = ["LICENSE_INCLUDED", "BRING_YOUR_OWN_LICENSE"]
270        if not value_allowed_none_or_none_sentinel(license_model, allowed_values):
271            raise ValueError(
272                "Invalid value for `license_model`, must be None or one of {0}"
273                .format(allowed_values)
274            )
275        self._license_model = license_model
276
277    @property
278    def nsg_ids(self):
279        """
280        Gets the nsg_ids of this CreateCloudAutonomousVmClusterDetails.
281        A list of the `OCIDs`__ of the network security groups (NSGs) that this resource belongs to. Setting this to an empty array after the list is created removes the resource from all NSGs. For more information about NSGs, see `Security Rules`__.
282        **NsgIds restrictions:**
283        - Autonomous Databases with private access require at least 1 Network Security Group (NSG). The nsgIds array cannot be empty.
284
285        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
286        __ https://docs.cloud.oracle.com/Content/Network/Concepts/securityrules.htm
287
288
289        :return: The nsg_ids of this CreateCloudAutonomousVmClusterDetails.
290        :rtype: list[str]
291        """
292        return self._nsg_ids
293
294    @nsg_ids.setter
295    def nsg_ids(self, nsg_ids):
296        """
297        Sets the nsg_ids of this CreateCloudAutonomousVmClusterDetails.
298        A list of the `OCIDs`__ of the network security groups (NSGs) that this resource belongs to. Setting this to an empty array after the list is created removes the resource from all NSGs. For more information about NSGs, see `Security Rules`__.
299        **NsgIds restrictions:**
300        - Autonomous Databases with private access require at least 1 Network Security Group (NSG). The nsgIds array cannot be empty.
301
302        __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm
303        __ https://docs.cloud.oracle.com/Content/Network/Concepts/securityrules.htm
304
305
306        :param nsg_ids: The nsg_ids of this CreateCloudAutonomousVmClusterDetails.
307        :type: list[str]
308        """
309        self._nsg_ids = nsg_ids
310
311    @property
312    def freeform_tags(self):
313        """
314        Gets the freeform_tags of this CreateCloudAutonomousVmClusterDetails.
315        Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace.
316        For more information, see `Resource Tags`__.
317
318        Example: `{\"Department\": \"Finance\"}`
319
320        __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm
321
322
323        :return: The freeform_tags of this CreateCloudAutonomousVmClusterDetails.
324        :rtype: dict(str, str)
325        """
326        return self._freeform_tags
327
328    @freeform_tags.setter
329    def freeform_tags(self, freeform_tags):
330        """
331        Sets the freeform_tags of this CreateCloudAutonomousVmClusterDetails.
332        Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace.
333        For more information, see `Resource Tags`__.
334
335        Example: `{\"Department\": \"Finance\"}`
336
337        __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm
338
339
340        :param freeform_tags: The freeform_tags of this CreateCloudAutonomousVmClusterDetails.
341        :type: dict(str, str)
342        """
343        self._freeform_tags = freeform_tags
344
345    @property
346    def defined_tags(self):
347        """
348        Gets the defined_tags of this CreateCloudAutonomousVmClusterDetails.
349        Defined tags for this resource. Each key is predefined and scoped to a namespace.
350        For more information, see `Resource Tags`__.
351
352        __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm
353
354
355        :return: The defined_tags of this CreateCloudAutonomousVmClusterDetails.
356        :rtype: dict(str, dict(str, object))
357        """
358        return self._defined_tags
359
360    @defined_tags.setter
361    def defined_tags(self, defined_tags):
362        """
363        Sets the defined_tags of this CreateCloudAutonomousVmClusterDetails.
364        Defined tags for this resource. Each key is predefined and scoped to a namespace.
365        For more information, see `Resource Tags`__.
366
367        __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm
368
369
370        :param defined_tags: The defined_tags of this CreateCloudAutonomousVmClusterDetails.
371        :type: dict(str, dict(str, object))
372        """
373        self._defined_tags = defined_tags
374
375    def __repr__(self):
376        return formatted_flat_dict(self)
377
378    def __eq__(self, other):
379        if other is None:
380            return False
381
382        return self.__dict__ == other.__dict__
383
384    def __ne__(self, other):
385        return not self == other
386