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 NetworkConfig(object):
12    """
13    Additional configuration of the user's network.
14    """
15
16    def __init__(self, **kwargs):
17        """
18        Initializes a new NetworkConfig object with values from keyword arguments.
19        The following keyword arguments are supported (corresponding to the getters/setters of this class):
20
21        :param is_nat_gateway_required:
22            The value to assign to the is_nat_gateway_required property of this NetworkConfig.
23        :type is_nat_gateway_required: bool
24
25        :param cidr_block:
26            The value to assign to the cidr_block property of this NetworkConfig.
27        :type cidr_block: str
28
29        """
30        self.swagger_types = {
31            'is_nat_gateway_required': 'bool',
32            'cidr_block': 'str'
33        }
34
35        self.attribute_map = {
36            'is_nat_gateway_required': 'isNatGatewayRequired',
37            'cidr_block': 'cidrBlock'
38        }
39
40        self._is_nat_gateway_required = None
41        self._cidr_block = None
42
43    @property
44    def is_nat_gateway_required(self):
45        """
46        Gets the is_nat_gateway_required of this NetworkConfig.
47        A boolean flag whether to configure a NAT gateway.
48
49
50        :return: The is_nat_gateway_required of this NetworkConfig.
51        :rtype: bool
52        """
53        return self._is_nat_gateway_required
54
55    @is_nat_gateway_required.setter
56    def is_nat_gateway_required(self, is_nat_gateway_required):
57        """
58        Sets the is_nat_gateway_required of this NetworkConfig.
59        A boolean flag whether to configure a NAT gateway.
60
61
62        :param is_nat_gateway_required: The is_nat_gateway_required of this NetworkConfig.
63        :type: bool
64        """
65        self._is_nat_gateway_required = is_nat_gateway_required
66
67    @property
68    def cidr_block(self):
69        """
70        Gets the cidr_block of this NetworkConfig.
71        The CIDR IP address block of the VCN.
72
73
74        :return: The cidr_block of this NetworkConfig.
75        :rtype: str
76        """
77        return self._cidr_block
78
79    @cidr_block.setter
80    def cidr_block(self, cidr_block):
81        """
82        Sets the cidr_block of this NetworkConfig.
83        The CIDR IP address block of the VCN.
84
85
86        :param cidr_block: The cidr_block of this NetworkConfig.
87        :type: str
88        """
89        self._cidr_block = cidr_block
90
91    def __repr__(self):
92        return formatted_flat_dict(self)
93
94    def __eq__(self, other):
95        if other is None:
96            return False
97
98        return self.__dict__ == other.__dict__
99
100    def __ne__(self, other):
101        return not self == other
102