|
| 1 | +# coding: utf-8 |
| 2 | + |
| 3 | +""" |
| 4 | + edx |
| 5 | +
|
| 6 | + No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501 |
| 7 | +
|
| 8 | + OpenAPI spec version: common-version |
| 9 | + |
| 10 | + Generated by: https://github.com/swagger-api/swagger-codegen.git |
| 11 | +""" |
| 12 | + |
| 13 | + |
| 14 | +import pprint |
| 15 | +import re # noqa: F401 |
| 16 | + |
| 17 | +import six |
| 18 | + |
| 19 | +from volcenginesdkcore.configuration import Configuration |
| 20 | + |
| 21 | + |
| 22 | +class AddRouteAggregationRequest(object): |
| 23 | + """NOTE: This class is auto generated by the swagger code generator program. |
| 24 | +
|
| 25 | + Do not edit the class manually. |
| 26 | + """ |
| 27 | + |
| 28 | + """ |
| 29 | + Attributes: |
| 30 | + swagger_types (dict): The key is attribute name |
| 31 | + and the value is attribute type. |
| 32 | + attribute_map (dict): The key is attribute name |
| 33 | + and the value is json key in definition. |
| 34 | + """ |
| 35 | + swagger_types = { |
| 36 | + 'aggregation_cidr': 'str', |
| 37 | + 'description': 'str', |
| 38 | + 'detail_suppressed': 'bool', |
| 39 | + 'direction': 'str', |
| 40 | + 'vif_instance_id': 'str' |
| 41 | + } |
| 42 | + |
| 43 | + attribute_map = { |
| 44 | + 'aggregation_cidr': 'AggregationCidr', |
| 45 | + 'description': 'Description', |
| 46 | + 'detail_suppressed': 'DetailSuppressed', |
| 47 | + 'direction': 'Direction', |
| 48 | + 'vif_instance_id': 'VIFInstanceId' |
| 49 | + } |
| 50 | + |
| 51 | + def __init__(self, aggregation_cidr=None, description=None, detail_suppressed=None, direction=None, vif_instance_id=None, _configuration=None): # noqa: E501 |
| 52 | + """AddRouteAggregationRequest - a model defined in Swagger""" # noqa: E501 |
| 53 | + if _configuration is None: |
| 54 | + _configuration = Configuration() |
| 55 | + self._configuration = _configuration |
| 56 | + |
| 57 | + self._aggregation_cidr = None |
| 58 | + self._description = None |
| 59 | + self._detail_suppressed = None |
| 60 | + self._direction = None |
| 61 | + self._vif_instance_id = None |
| 62 | + self.discriminator = None |
| 63 | + |
| 64 | + self.aggregation_cidr = aggregation_cidr |
| 65 | + if description is not None: |
| 66 | + self.description = description |
| 67 | + if detail_suppressed is not None: |
| 68 | + self.detail_suppressed = detail_suppressed |
| 69 | + self.direction = direction |
| 70 | + self.vif_instance_id = vif_instance_id |
| 71 | + |
| 72 | + @property |
| 73 | + def aggregation_cidr(self): |
| 74 | + """Gets the aggregation_cidr of this AddRouteAggregationRequest. # noqa: E501 |
| 75 | +
|
| 76 | +
|
| 77 | + :return: The aggregation_cidr of this AddRouteAggregationRequest. # noqa: E501 |
| 78 | + :rtype: str |
| 79 | + """ |
| 80 | + return self._aggregation_cidr |
| 81 | + |
| 82 | + @aggregation_cidr.setter |
| 83 | + def aggregation_cidr(self, aggregation_cidr): |
| 84 | + """Sets the aggregation_cidr of this AddRouteAggregationRequest. |
| 85 | +
|
| 86 | +
|
| 87 | + :param aggregation_cidr: The aggregation_cidr of this AddRouteAggregationRequest. # noqa: E501 |
| 88 | + :type: str |
| 89 | + """ |
| 90 | + if self._configuration.client_side_validation and aggregation_cidr is None: |
| 91 | + raise ValueError("Invalid value for `aggregation_cidr`, must not be `None`") # noqa: E501 |
| 92 | + |
| 93 | + self._aggregation_cidr = aggregation_cidr |
| 94 | + |
| 95 | + @property |
| 96 | + def description(self): |
| 97 | + """Gets the description of this AddRouteAggregationRequest. # noqa: E501 |
| 98 | +
|
| 99 | +
|
| 100 | + :return: The description of this AddRouteAggregationRequest. # noqa: E501 |
| 101 | + :rtype: str |
| 102 | + """ |
| 103 | + return self._description |
| 104 | + |
| 105 | + @description.setter |
| 106 | + def description(self, description): |
| 107 | + """Sets the description of this AddRouteAggregationRequest. |
| 108 | +
|
| 109 | +
|
| 110 | + :param description: The description of this AddRouteAggregationRequest. # noqa: E501 |
| 111 | + :type: str |
| 112 | + """ |
| 113 | + |
| 114 | + self._description = description |
| 115 | + |
| 116 | + @property |
| 117 | + def detail_suppressed(self): |
| 118 | + """Gets the detail_suppressed of this AddRouteAggregationRequest. # noqa: E501 |
| 119 | +
|
| 120 | +
|
| 121 | + :return: The detail_suppressed of this AddRouteAggregationRequest. # noqa: E501 |
| 122 | + :rtype: bool |
| 123 | + """ |
| 124 | + return self._detail_suppressed |
| 125 | + |
| 126 | + @detail_suppressed.setter |
| 127 | + def detail_suppressed(self, detail_suppressed): |
| 128 | + """Sets the detail_suppressed of this AddRouteAggregationRequest. |
| 129 | +
|
| 130 | +
|
| 131 | + :param detail_suppressed: The detail_suppressed of this AddRouteAggregationRequest. # noqa: E501 |
| 132 | + :type: bool |
| 133 | + """ |
| 134 | + |
| 135 | + self._detail_suppressed = detail_suppressed |
| 136 | + |
| 137 | + @property |
| 138 | + def direction(self): |
| 139 | + """Gets the direction of this AddRouteAggregationRequest. # noqa: E501 |
| 140 | +
|
| 141 | +
|
| 142 | + :return: The direction of this AddRouteAggregationRequest. # noqa: E501 |
| 143 | + :rtype: str |
| 144 | + """ |
| 145 | + return self._direction |
| 146 | + |
| 147 | + @direction.setter |
| 148 | + def direction(self, direction): |
| 149 | + """Sets the direction of this AddRouteAggregationRequest. |
| 150 | +
|
| 151 | +
|
| 152 | + :param direction: The direction of this AddRouteAggregationRequest. # noqa: E501 |
| 153 | + :type: str |
| 154 | + """ |
| 155 | + if self._configuration.client_side_validation and direction is None: |
| 156 | + raise ValueError("Invalid value for `direction`, must not be `None`") # noqa: E501 |
| 157 | + |
| 158 | + self._direction = direction |
| 159 | + |
| 160 | + @property |
| 161 | + def vif_instance_id(self): |
| 162 | + """Gets the vif_instance_id of this AddRouteAggregationRequest. # noqa: E501 |
| 163 | +
|
| 164 | +
|
| 165 | + :return: The vif_instance_id of this AddRouteAggregationRequest. # noqa: E501 |
| 166 | + :rtype: str |
| 167 | + """ |
| 168 | + return self._vif_instance_id |
| 169 | + |
| 170 | + @vif_instance_id.setter |
| 171 | + def vif_instance_id(self, vif_instance_id): |
| 172 | + """Sets the vif_instance_id of this AddRouteAggregationRequest. |
| 173 | +
|
| 174 | +
|
| 175 | + :param vif_instance_id: The vif_instance_id of this AddRouteAggregationRequest. # noqa: E501 |
| 176 | + :type: str |
| 177 | + """ |
| 178 | + if self._configuration.client_side_validation and vif_instance_id is None: |
| 179 | + raise ValueError("Invalid value for `vif_instance_id`, must not be `None`") # noqa: E501 |
| 180 | + |
| 181 | + self._vif_instance_id = vif_instance_id |
| 182 | + |
| 183 | + def to_dict(self): |
| 184 | + """Returns the model properties as a dict""" |
| 185 | + result = {} |
| 186 | + |
| 187 | + for attr, _ in six.iteritems(self.swagger_types): |
| 188 | + value = getattr(self, attr) |
| 189 | + if isinstance(value, list): |
| 190 | + result[attr] = list(map( |
| 191 | + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, |
| 192 | + value |
| 193 | + )) |
| 194 | + elif hasattr(value, "to_dict"): |
| 195 | + result[attr] = value.to_dict() |
| 196 | + elif isinstance(value, dict): |
| 197 | + result[attr] = dict(map( |
| 198 | + lambda item: (item[0], item[1].to_dict()) |
| 199 | + if hasattr(item[1], "to_dict") else item, |
| 200 | + value.items() |
| 201 | + )) |
| 202 | + else: |
| 203 | + result[attr] = value |
| 204 | + if issubclass(AddRouteAggregationRequest, dict): |
| 205 | + for key, value in self.items(): |
| 206 | + result[key] = value |
| 207 | + |
| 208 | + return result |
| 209 | + |
| 210 | + def to_str(self): |
| 211 | + """Returns the string representation of the model""" |
| 212 | + return pprint.pformat(self.to_dict()) |
| 213 | + |
| 214 | + def __repr__(self): |
| 215 | + """For `print` and `pprint`""" |
| 216 | + return self.to_str() |
| 217 | + |
| 218 | + def __eq__(self, other): |
| 219 | + """Returns true if both objects are equal""" |
| 220 | + if not isinstance(other, AddRouteAggregationRequest): |
| 221 | + return False |
| 222 | + |
| 223 | + return self.to_dict() == other.to_dict() |
| 224 | + |
| 225 | + def __ne__(self, other): |
| 226 | + """Returns true if both objects are not equal""" |
| 227 | + if not isinstance(other, AddRouteAggregationRequest): |
| 228 | + return True |
| 229 | + |
| 230 | + return self.to_dict() != other.to_dict() |
0 commit comments