huaweicloudsdkclouddc 3.1.158__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of huaweicloudsdkclouddc might be problematic. Click here for more details.

Files changed (142) hide show
  1. huaweicloudsdkclouddc/__init__.py +0 -0
  2. huaweicloudsdkclouddc/v1/__init__.py +138 -0
  3. huaweicloudsdkclouddc/v1/clouddc_async_client.py +2255 -0
  4. huaweicloudsdkclouddc/v1/clouddc_client.py +2252 -0
  5. huaweicloudsdkclouddc/v1/model/__init__.py +135 -0
  6. huaweicloudsdkclouddc/v1/model/alarm_daily_trend.py +173 -0
  7. huaweicloudsdkclouddc/v1/model/alarm_device_info.py +144 -0
  8. huaweicloudsdkclouddc/v1/model/alarm_group.py +173 -0
  9. huaweicloudsdkclouddc/v1/model/alarm_history.py +343 -0
  10. huaweicloudsdkclouddc/v1/model/alarm_host.py +173 -0
  11. huaweicloudsdkclouddc/v1/model/alarm_info.py +173 -0
  12. huaweicloudsdkclouddc/v1/model/alarm_level_info.py +144 -0
  13. huaweicloudsdkclouddc/v1/model/batch_create_irack_tags_request.py +139 -0
  14. huaweicloudsdkclouddc/v1/model/batch_create_irack_tags_response.py +85 -0
  15. huaweicloudsdkclouddc/v1/model/batch_create_tags_request.py +167 -0
  16. huaweicloudsdkclouddc/v1/model/batch_create_tags_response.py +85 -0
  17. huaweicloudsdkclouddc/v1/model/batch_delete_irack_tags_request.py +139 -0
  18. huaweicloudsdkclouddc/v1/model/batch_delete_irack_tags_response.py +85 -0
  19. huaweicloudsdkclouddc/v1/model/batch_delete_options.py +115 -0
  20. huaweicloudsdkclouddc/v1/model/batch_delete_tags_request.py +167 -0
  21. huaweicloudsdkclouddc/v1/model/batch_delete_tags_response.py +85 -0
  22. huaweicloudsdkclouddc/v1/model/capacity_bytes.py +84 -0
  23. huaweicloudsdkclouddc/v1/model/change_instance_password_options.py +143 -0
  24. huaweicloudsdkclouddc/v1/model/change_instance_password_request.py +111 -0
  25. huaweicloudsdkclouddc/v1/model/change_instance_password_response.py +116 -0
  26. huaweicloudsdkclouddc/v1/model/change_server_power_state_request.py +111 -0
  27. huaweicloudsdkclouddc/v1/model/change_server_power_state_response.py +116 -0
  28. huaweicloudsdkclouddc/v1/model/create_instance_opitons.py +305 -0
  29. huaweicloudsdkclouddc/v1/model/create_instance_opitons_placement.py +115 -0
  30. huaweicloudsdkclouddc/v1/model/create_instance_request.py +111 -0
  31. huaweicloudsdkclouddc/v1/model/create_instance_response.py +116 -0
  32. huaweicloudsdkclouddc/v1/model/delete_instance_request.py +114 -0
  33. huaweicloudsdkclouddc/v1/model/delete_instance_response.py +112 -0
  34. huaweicloudsdkclouddc/v1/model/delete_instances_request.py +111 -0
  35. huaweicloudsdkclouddc/v1/model/delete_instances_response.py +116 -0
  36. huaweicloudsdkclouddc/v1/model/dimension.py +144 -0
  37. huaweicloudsdkclouddc/v1/model/download_server_logs_request.py +142 -0
  38. huaweicloudsdkclouddc/v1/model/download_server_logs_response.py +162 -0
  39. huaweicloudsdkclouddc/v1/model/drive.py +637 -0
  40. huaweicloudsdkclouddc/v1/model/error_status.py +170 -0
  41. huaweicloudsdkclouddc/v1/model/event_info.py +318 -0
  42. huaweicloudsdkclouddc/v1/model/export_server_logs_request.py +114 -0
  43. huaweicloudsdkclouddc/v1/model/export_server_logs_response.py +278 -0
  44. huaweicloudsdkclouddc/v1/model/fan.py +285 -0
  45. huaweicloudsdkclouddc/v1/model/fault_host_info.py +173 -0
  46. huaweicloudsdkclouddc/v1/model/firmware_details.py +202 -0
  47. huaweicloudsdkclouddc/v1/model/hardware_summary.py +199 -0
  48. huaweicloudsdkclouddc/v1/model/health.py +90 -0
  49. huaweicloudsdkclouddc/v1/model/i_dc.py +208 -0
  50. huaweicloudsdkclouddc/v1/model/i_rack.py +521 -0
  51. huaweicloudsdkclouddc/v1/model/i_rack_request.py +115 -0
  52. huaweicloudsdkclouddc/v1/model/image.py +170 -0
  53. huaweicloudsdkclouddc/v1/model/image_id.py +84 -0
  54. huaweicloudsdkclouddc/v1/model/instance.py +280 -0
  55. huaweicloudsdkclouddc/v1/model/instance_id.py +84 -0
  56. huaweicloudsdkclouddc/v1/model/instance_state.py +94 -0
  57. huaweicloudsdkclouddc/v1/model/list_alarms_request.py +347 -0
  58. huaweicloudsdkclouddc/v1/model/list_alarms_response.py +145 -0
  59. huaweicloudsdkclouddc/v1/model/list_events_request.py +260 -0
  60. huaweicloudsdkclouddc/v1/model/list_events_response.py +145 -0
  61. huaweicloudsdkclouddc/v1/model/list_i_dcs_request.py +201 -0
  62. huaweicloudsdkclouddc/v1/model/list_i_dcs_response.py +137 -0
  63. huaweicloudsdkclouddc/v1/model/list_i_rack_request.py +201 -0
  64. huaweicloudsdkclouddc/v1/model/list_i_rack_response.py +137 -0
  65. huaweicloudsdkclouddc/v1/model/list_instances_request.py +231 -0
  66. huaweicloudsdkclouddc/v1/model/list_instances_response.py +170 -0
  67. huaweicloudsdkclouddc/v1/model/list_servers_request.py +173 -0
  68. huaweicloudsdkclouddc/v1/model/list_servers_response.py +170 -0
  69. huaweicloudsdkclouddc/v1/model/location.py +173 -0
  70. huaweicloudsdkclouddc/v1/model/manage_state.py +91 -0
  71. huaweicloudsdkclouddc/v1/model/memory.py +579 -0
  72. huaweicloudsdkclouddc/v1/model/metric.py +144 -0
  73. huaweicloudsdkclouddc/v1/model/modify_instance_ip_request.py +139 -0
  74. huaweicloudsdkclouddc/v1/model/modify_instance_ip_request_body.py +144 -0
  75. huaweicloudsdkclouddc/v1/model/modify_instance_ip_request_body_nics.py +143 -0
  76. huaweicloudsdkclouddc/v1/model/modify_instance_ip_response.py +85 -0
  77. huaweicloudsdkclouddc/v1/model/network_adapter.py +492 -0
  78. huaweicloudsdkclouddc/v1/model/network_interface.py +143 -0
  79. huaweicloudsdkclouddc/v1/model/network_port.py +347 -0
  80. huaweicloudsdkclouddc/v1/model/page_info.py +173 -0
  81. huaweicloudsdkclouddc/v1/model/password.py +84 -0
  82. huaweicloudsdkclouddc/v1/model/physical_server.py +402 -0
  83. huaweicloudsdkclouddc/v1/model/power.py +488 -0
  84. huaweicloudsdkclouddc/v1/model/power_action.py +143 -0
  85. huaweicloudsdkclouddc/v1/model/power_state.py +91 -0
  86. huaweicloudsdkclouddc/v1/model/processors.py +608 -0
  87. huaweicloudsdkclouddc/v1/model/query_instance_response_body.py +499 -0
  88. huaweicloudsdkclouddc/v1/model/reinstall_os_options.py +172 -0
  89. huaweicloudsdkclouddc/v1/model/reinstall_os_request.py +111 -0
  90. huaweicloudsdkclouddc/v1/model/reinstall_os_response.py +116 -0
  91. huaweicloudsdkclouddc/v1/model/resource_name.py +84 -0
  92. huaweicloudsdkclouddc/v1/model/resource_tags.py +115 -0
  93. huaweicloudsdkclouddc/v1/model/resource_uuid.py +84 -0
  94. huaweicloudsdkclouddc/v1/model/run_instances_options.py +367 -0
  95. huaweicloudsdkclouddc/v1/model/run_instances_options_network_interfaces.py +114 -0
  96. huaweicloudsdkclouddc/v1/model/run_instances_options_placement.py +115 -0
  97. huaweicloudsdkclouddc/v1/model/run_instances_request.py +111 -0
  98. huaweicloudsdkclouddc/v1/model/run_instances_response.py +116 -0
  99. huaweicloudsdkclouddc/v1/model/sas_address.py +84 -0
  100. huaweicloudsdkclouddc/v1/model/server_instance_id_set.py +115 -0
  101. huaweicloudsdkclouddc/v1/model/server_power_status.py +171 -0
  102. huaweicloudsdkclouddc/v1/model/server_state.py +142 -0
  103. huaweicloudsdkclouddc/v1/model/server_status.py +279 -0
  104. huaweicloudsdkclouddc/v1/model/servers_response_physical_servers.py +115 -0
  105. huaweicloudsdkclouddc/v1/model/show_alarm_summary_request.py +84 -0
  106. huaweicloudsdkclouddc/v1/model/show_alarm_summary_response.py +203 -0
  107. huaweicloudsdkclouddc/v1/model/show_alarm_trend_request.py +142 -0
  108. huaweicloudsdkclouddc/v1/model/show_alarm_trend_response.py +145 -0
  109. huaweicloudsdkclouddc/v1/model/show_event_request.py +114 -0
  110. huaweicloudsdkclouddc/v1/model/show_event_response.py +377 -0
  111. huaweicloudsdkclouddc/v1/model/show_instance_status_request.py +114 -0
  112. huaweicloudsdkclouddc/v1/model/show_instance_status_response.py +137 -0
  113. huaweicloudsdkclouddc/v1/model/show_logs_export_status_request.py +142 -0
  114. huaweicloudsdkclouddc/v1/model/show_logs_export_status_response.py +203 -0
  115. huaweicloudsdkclouddc/v1/model/show_remote_console_request.py +114 -0
  116. huaweicloudsdkclouddc/v1/model/show_remote_console_response.py +116 -0
  117. huaweicloudsdkclouddc/v1/model/show_server_firmware_attributes_request.py +114 -0
  118. huaweicloudsdkclouddc/v1/model/show_server_firmware_attributes_response.py +116 -0
  119. huaweicloudsdkclouddc/v1/model/show_server_hardware_attributes_request.py +114 -0
  120. huaweicloudsdkclouddc/v1/model/show_server_hardware_attributes_response.py +286 -0
  121. huaweicloudsdkclouddc/v1/model/show_server_request.py +114 -0
  122. huaweicloudsdkclouddc/v1/model/show_server_response.py +411 -0
  123. huaweicloudsdkclouddc/v1/model/show_server_status_request.py +84 -0
  124. huaweicloudsdkclouddc/v1/model/show_server_status_response.py +137 -0
  125. huaweicloudsdkclouddc/v1/model/state.py +89 -0
  126. huaweicloudsdkclouddc/v1/model/status.py +136 -0
  127. huaweicloudsdkclouddc/v1/model/storage_controller.py +608 -0
  128. huaweicloudsdkclouddc/v1/model/tag.py +143 -0
  129. huaweicloudsdkclouddc/v1/model/update_i_dcs_request.py +111 -0
  130. huaweicloudsdkclouddc/v1/model/update_i_dcs_response.py +112 -0
  131. huaweicloudsdkclouddc/v1/model/update_i_rack_request.py +139 -0
  132. huaweicloudsdkclouddc/v1/model/update_i_rack_response.py +112 -0
  133. huaweicloudsdkclouddc/v1/model/user_data.py +84 -0
  134. huaweicloudsdkclouddc/v1/model/volume.py +459 -0
  135. huaweicloudsdkclouddc/v1/model/vpc_id.py +84 -0
  136. huaweicloudsdkclouddc/v1/region/__init__.py +0 -0
  137. huaweicloudsdkclouddc/v1/region/clouddc_region.py +40 -0
  138. huaweicloudsdkclouddc-3.1.158.dist-info/LICENSE +13 -0
  139. huaweicloudsdkclouddc-3.1.158.dist-info/METADATA +27 -0
  140. huaweicloudsdkclouddc-3.1.158.dist-info/RECORD +142 -0
  141. huaweicloudsdkclouddc-3.1.158.dist-info/WHEEL +6 -0
  142. huaweicloudsdkclouddc-3.1.158.dist-info/top_level.txt +1 -0
@@ -0,0 +1,144 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class Metric:
9
+
10
+ """
11
+ Attributes:
12
+ openapi_types (dict): The key is attribute name
13
+ and the value is attribute type.
14
+ attribute_map (dict): The key is attribute name
15
+ and the value is json key in definition.
16
+ """
17
+ sensitive_list = []
18
+
19
+ openapi_types = {
20
+ 'metric_name': 'str',
21
+ 'dimensions': 'list[Dimension]'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'metric_name': 'metric_name',
26
+ 'dimensions': 'dimensions'
27
+ }
28
+
29
+ def __init__(self, metric_name=None, dimensions=None):
30
+ r"""Metric
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param metric_name: 资源的监控指标名称,必须以字母开头,只能包含0-9/a-z/A-Z/_,字符长度最短为1,最大为64;如:弹性云服务器中的监控指标cpu_util,表示弹性服务器的CPU使用率;文档数据库中的指标mongo001_command_ps,表示command执行频率;各服务的指标名称可查看:[服务指标名称](https://support.huaweicloud.com/usermanual-ces/zh-cn_topic_0202622212.html)。
35
+ :type metric_name: str
36
+ :param dimensions: 资源维度
37
+ :type dimensions: list[:class:`huaweicloudsdkclouddc.v1.Dimension`]
38
+ """
39
+
40
+
41
+
42
+ self._metric_name = None
43
+ self._dimensions = None
44
+ self.discriminator = None
45
+
46
+ if metric_name is not None:
47
+ self.metric_name = metric_name
48
+ if dimensions is not None:
49
+ self.dimensions = dimensions
50
+
51
+ @property
52
+ def metric_name(self):
53
+ r"""Gets the metric_name of this Metric.
54
+
55
+ 资源的监控指标名称,必须以字母开头,只能包含0-9/a-z/A-Z/_,字符长度最短为1,最大为64;如:弹性云服务器中的监控指标cpu_util,表示弹性服务器的CPU使用率;文档数据库中的指标mongo001_command_ps,表示command执行频率;各服务的指标名称可查看:[服务指标名称](https://support.huaweicloud.com/usermanual-ces/zh-cn_topic_0202622212.html)。
56
+
57
+ :return: The metric_name of this Metric.
58
+ :rtype: str
59
+ """
60
+ return self._metric_name
61
+
62
+ @metric_name.setter
63
+ def metric_name(self, metric_name):
64
+ r"""Sets the metric_name of this Metric.
65
+
66
+ 资源的监控指标名称,必须以字母开头,只能包含0-9/a-z/A-Z/_,字符长度最短为1,最大为64;如:弹性云服务器中的监控指标cpu_util,表示弹性服务器的CPU使用率;文档数据库中的指标mongo001_command_ps,表示command执行频率;各服务的指标名称可查看:[服务指标名称](https://support.huaweicloud.com/usermanual-ces/zh-cn_topic_0202622212.html)。
67
+
68
+ :param metric_name: The metric_name of this Metric.
69
+ :type metric_name: str
70
+ """
71
+ self._metric_name = metric_name
72
+
73
+ @property
74
+ def dimensions(self):
75
+ r"""Gets the dimensions of this Metric.
76
+
77
+ 资源维度
78
+
79
+ :return: The dimensions of this Metric.
80
+ :rtype: list[:class:`huaweicloudsdkclouddc.v1.Dimension`]
81
+ """
82
+ return self._dimensions
83
+
84
+ @dimensions.setter
85
+ def dimensions(self, dimensions):
86
+ r"""Sets the dimensions of this Metric.
87
+
88
+ 资源维度
89
+
90
+ :param dimensions: The dimensions of this Metric.
91
+ :type dimensions: list[:class:`huaweicloudsdkclouddc.v1.Dimension`]
92
+ """
93
+ self._dimensions = dimensions
94
+
95
+ def to_dict(self):
96
+ """Returns the model properties as a dict"""
97
+ result = {}
98
+
99
+ for attr, _ in six.iteritems(self.openapi_types):
100
+ value = getattr(self, attr)
101
+ if isinstance(value, list):
102
+ result[attr] = list(map(
103
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
104
+ value
105
+ ))
106
+ elif hasattr(value, "to_dict"):
107
+ result[attr] = value.to_dict()
108
+ elif isinstance(value, dict):
109
+ result[attr] = dict(map(
110
+ lambda item: (item[0], item[1].to_dict())
111
+ if hasattr(item[1], "to_dict") else item,
112
+ value.items()
113
+ ))
114
+ else:
115
+ if attr in self.sensitive_list:
116
+ result[attr] = "****"
117
+ else:
118
+ result[attr] = value
119
+
120
+ return result
121
+
122
+ def to_str(self):
123
+ """Returns the string representation of the model"""
124
+ import simplejson as json
125
+ if six.PY2:
126
+ import sys
127
+ reload(sys)
128
+ sys.setdefaultencoding("utf-8")
129
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
130
+
131
+ def __repr__(self):
132
+ """For `print`"""
133
+ return self.to_str()
134
+
135
+ def __eq__(self, other):
136
+ """Returns true if both objects are equal"""
137
+ if not isinstance(other, Metric):
138
+ return False
139
+
140
+ return self.__dict__ == other.__dict__
141
+
142
+ def __ne__(self, other):
143
+ """Returns true if both objects are not equal"""
144
+ return not self == other
@@ -0,0 +1,139 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class ModifyInstanceIpRequest:
9
+
10
+ """
11
+ Attributes:
12
+ openapi_types (dict): The key is attribute name
13
+ and the value is attribute type.
14
+ attribute_map (dict): The key is attribute name
15
+ and the value is json key in definition.
16
+ """
17
+ sensitive_list = []
18
+
19
+ openapi_types = {
20
+ 'id': 'str',
21
+ 'body': 'ModifyInstanceIpRequestBody'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'id': 'id',
26
+ 'body': 'body'
27
+ }
28
+
29
+ def __init__(self, id=None, body=None):
30
+ r"""ModifyInstanceIpRequest
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param id: imetal instance id
35
+ :type id: str
36
+ :param body: Body of the ModifyInstanceIpRequest
37
+ :type body: :class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBody`
38
+ """
39
+
40
+
41
+
42
+ self._id = None
43
+ self._body = None
44
+ self.discriminator = None
45
+
46
+ self.id = id
47
+ if body is not None:
48
+ self.body = body
49
+
50
+ @property
51
+ def id(self):
52
+ r"""Gets the id of this ModifyInstanceIpRequest.
53
+
54
+ imetal instance id
55
+
56
+ :return: The id of this ModifyInstanceIpRequest.
57
+ :rtype: str
58
+ """
59
+ return self._id
60
+
61
+ @id.setter
62
+ def id(self, id):
63
+ r"""Sets the id of this ModifyInstanceIpRequest.
64
+
65
+ imetal instance id
66
+
67
+ :param id: The id of this ModifyInstanceIpRequest.
68
+ :type id: str
69
+ """
70
+ self._id = id
71
+
72
+ @property
73
+ def body(self):
74
+ r"""Gets the body of this ModifyInstanceIpRequest.
75
+
76
+ :return: The body of this ModifyInstanceIpRequest.
77
+ :rtype: :class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBody`
78
+ """
79
+ return self._body
80
+
81
+ @body.setter
82
+ def body(self, body):
83
+ r"""Sets the body of this ModifyInstanceIpRequest.
84
+
85
+ :param body: The body of this ModifyInstanceIpRequest.
86
+ :type body: :class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBody`
87
+ """
88
+ self._body = body
89
+
90
+ def to_dict(self):
91
+ """Returns the model properties as a dict"""
92
+ result = {}
93
+
94
+ for attr, _ in six.iteritems(self.openapi_types):
95
+ value = getattr(self, attr)
96
+ if isinstance(value, list):
97
+ result[attr] = list(map(
98
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
99
+ value
100
+ ))
101
+ elif hasattr(value, "to_dict"):
102
+ result[attr] = value.to_dict()
103
+ elif isinstance(value, dict):
104
+ result[attr] = dict(map(
105
+ lambda item: (item[0], item[1].to_dict())
106
+ if hasattr(item[1], "to_dict") else item,
107
+ value.items()
108
+ ))
109
+ else:
110
+ if attr in self.sensitive_list:
111
+ result[attr] = "****"
112
+ else:
113
+ result[attr] = value
114
+
115
+ return result
116
+
117
+ def to_str(self):
118
+ """Returns the string representation of the model"""
119
+ import simplejson as json
120
+ if six.PY2:
121
+ import sys
122
+ reload(sys)
123
+ sys.setdefaultencoding("utf-8")
124
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
125
+
126
+ def __repr__(self):
127
+ """For `print`"""
128
+ return self.to_str()
129
+
130
+ def __eq__(self, other):
131
+ """Returns true if both objects are equal"""
132
+ if not isinstance(other, ModifyInstanceIpRequest):
133
+ return False
134
+
135
+ return self.__dict__ == other.__dict__
136
+
137
+ def __ne__(self, other):
138
+ """Returns true if both objects are not equal"""
139
+ return not self == other
@@ -0,0 +1,144 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class ModifyInstanceIpRequestBody:
9
+
10
+ """
11
+ Attributes:
12
+ openapi_types (dict): The key is attribute name
13
+ and the value is attribute type.
14
+ attribute_map (dict): The key is attribute name
15
+ and the value is json key in definition.
16
+ """
17
+ sensitive_list = []
18
+
19
+ openapi_types = {
20
+ 'vpc_id': 'str',
21
+ 'nics': 'list[ModifyInstanceIpRequestBodyNics]'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'vpc_id': 'vpc_id',
26
+ 'nics': 'nics'
27
+ }
28
+
29
+ def __init__(self, vpc_id=None, nics=None):
30
+ r"""ModifyInstanceIpRequestBody
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param vpc_id: 创建网卡所属的 VPC ID,可通过 VPC API 查询:https://support.huaweicloud.com/api-vpc/vpc_api01_0003.html。
35
+ :type vpc_id: str
36
+ :param nics: 网卡信息
37
+ :type nics: list[:class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBodyNics`]
38
+ """
39
+
40
+
41
+
42
+ self._vpc_id = None
43
+ self._nics = None
44
+ self.discriminator = None
45
+
46
+ if vpc_id is not None:
47
+ self.vpc_id = vpc_id
48
+ if nics is not None:
49
+ self.nics = nics
50
+
51
+ @property
52
+ def vpc_id(self):
53
+ r"""Gets the vpc_id of this ModifyInstanceIpRequestBody.
54
+
55
+ 创建网卡所属的 VPC ID,可通过 VPC API 查询:https://support.huaweicloud.com/api-vpc/vpc_api01_0003.html。
56
+
57
+ :return: The vpc_id of this ModifyInstanceIpRequestBody.
58
+ :rtype: str
59
+ """
60
+ return self._vpc_id
61
+
62
+ @vpc_id.setter
63
+ def vpc_id(self, vpc_id):
64
+ r"""Sets the vpc_id of this ModifyInstanceIpRequestBody.
65
+
66
+ 创建网卡所属的 VPC ID,可通过 VPC API 查询:https://support.huaweicloud.com/api-vpc/vpc_api01_0003.html。
67
+
68
+ :param vpc_id: The vpc_id of this ModifyInstanceIpRequestBody.
69
+ :type vpc_id: str
70
+ """
71
+ self._vpc_id = vpc_id
72
+
73
+ @property
74
+ def nics(self):
75
+ r"""Gets the nics of this ModifyInstanceIpRequestBody.
76
+
77
+ 网卡信息
78
+
79
+ :return: The nics of this ModifyInstanceIpRequestBody.
80
+ :rtype: list[:class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBodyNics`]
81
+ """
82
+ return self._nics
83
+
84
+ @nics.setter
85
+ def nics(self, nics):
86
+ r"""Sets the nics of this ModifyInstanceIpRequestBody.
87
+
88
+ 网卡信息
89
+
90
+ :param nics: The nics of this ModifyInstanceIpRequestBody.
91
+ :type nics: list[:class:`huaweicloudsdkclouddc.v1.ModifyInstanceIpRequestBodyNics`]
92
+ """
93
+ self._nics = nics
94
+
95
+ def to_dict(self):
96
+ """Returns the model properties as a dict"""
97
+ result = {}
98
+
99
+ for attr, _ in six.iteritems(self.openapi_types):
100
+ value = getattr(self, attr)
101
+ if isinstance(value, list):
102
+ result[attr] = list(map(
103
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
104
+ value
105
+ ))
106
+ elif hasattr(value, "to_dict"):
107
+ result[attr] = value.to_dict()
108
+ elif isinstance(value, dict):
109
+ result[attr] = dict(map(
110
+ lambda item: (item[0], item[1].to_dict())
111
+ if hasattr(item[1], "to_dict") else item,
112
+ value.items()
113
+ ))
114
+ else:
115
+ if attr in self.sensitive_list:
116
+ result[attr] = "****"
117
+ else:
118
+ result[attr] = value
119
+
120
+ return result
121
+
122
+ def to_str(self):
123
+ """Returns the string representation of the model"""
124
+ import simplejson as json
125
+ if six.PY2:
126
+ import sys
127
+ reload(sys)
128
+ sys.setdefaultencoding("utf-8")
129
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
130
+
131
+ def __repr__(self):
132
+ """For `print`"""
133
+ return self.to_str()
134
+
135
+ def __eq__(self, other):
136
+ """Returns true if both objects are equal"""
137
+ if not isinstance(other, ModifyInstanceIpRequestBody):
138
+ return False
139
+
140
+ return self.__dict__ == other.__dict__
141
+
142
+ def __ne__(self, other):
143
+ """Returns true if both objects are not equal"""
144
+ return not self == other
@@ -0,0 +1,143 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class ModifyInstanceIpRequestBodyNics:
9
+
10
+ """
11
+ Attributes:
12
+ openapi_types (dict): The key is attribute name
13
+ and the value is attribute type.
14
+ attribute_map (dict): The key is attribute name
15
+ and the value is json key in definition.
16
+ """
17
+ sensitive_list = []
18
+
19
+ openapi_types = {
20
+ 'subnet_id': 'str',
21
+ 'ip_address': 'str'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'subnet_id': 'subnet_id',
26
+ 'ip_address': 'ip_address'
27
+ }
28
+
29
+ def __init__(self, subnet_id=None, ip_address=None):
30
+ r"""ModifyInstanceIpRequestBodyNics
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param subnet_id: 创建网卡所属 CloudDCN 子网 ID,可通过 CloudDCN API 查询:https://support.huaweicloud.com/api-vpc/vpc_subnet01_0003.html。
35
+ :type subnet_id: str
36
+ :param ip_address: 创建网卡指定静态IP,批量安装时,该参数不生效。不填或空字符串,默认在子网(subnet)中自动分配一个未使用的IP作网卡的IP地址。若指定IP地址,该IP地址必须在子网(subnet)对应的网段内,且未被使用。
37
+ :type ip_address: str
38
+ """
39
+
40
+
41
+
42
+ self._subnet_id = None
43
+ self._ip_address = None
44
+ self.discriminator = None
45
+
46
+ self.subnet_id = subnet_id
47
+ if ip_address is not None:
48
+ self.ip_address = ip_address
49
+
50
+ @property
51
+ def subnet_id(self):
52
+ r"""Gets the subnet_id of this ModifyInstanceIpRequestBodyNics.
53
+
54
+ 创建网卡所属 CloudDCN 子网 ID,可通过 CloudDCN API 查询:https://support.huaweicloud.com/api-vpc/vpc_subnet01_0003.html。
55
+
56
+ :return: The subnet_id of this ModifyInstanceIpRequestBodyNics.
57
+ :rtype: str
58
+ """
59
+ return self._subnet_id
60
+
61
+ @subnet_id.setter
62
+ def subnet_id(self, subnet_id):
63
+ r"""Sets the subnet_id of this ModifyInstanceIpRequestBodyNics.
64
+
65
+ 创建网卡所属 CloudDCN 子网 ID,可通过 CloudDCN API 查询:https://support.huaweicloud.com/api-vpc/vpc_subnet01_0003.html。
66
+
67
+ :param subnet_id: The subnet_id of this ModifyInstanceIpRequestBodyNics.
68
+ :type subnet_id: str
69
+ """
70
+ self._subnet_id = subnet_id
71
+
72
+ @property
73
+ def ip_address(self):
74
+ r"""Gets the ip_address of this ModifyInstanceIpRequestBodyNics.
75
+
76
+ 创建网卡指定静态IP,批量安装时,该参数不生效。不填或空字符串,默认在子网(subnet)中自动分配一个未使用的IP作网卡的IP地址。若指定IP地址,该IP地址必须在子网(subnet)对应的网段内,且未被使用。
77
+
78
+ :return: The ip_address of this ModifyInstanceIpRequestBodyNics.
79
+ :rtype: str
80
+ """
81
+ return self._ip_address
82
+
83
+ @ip_address.setter
84
+ def ip_address(self, ip_address):
85
+ r"""Sets the ip_address of this ModifyInstanceIpRequestBodyNics.
86
+
87
+ 创建网卡指定静态IP,批量安装时,该参数不生效。不填或空字符串,默认在子网(subnet)中自动分配一个未使用的IP作网卡的IP地址。若指定IP地址,该IP地址必须在子网(subnet)对应的网段内,且未被使用。
88
+
89
+ :param ip_address: The ip_address of this ModifyInstanceIpRequestBodyNics.
90
+ :type ip_address: str
91
+ """
92
+ self._ip_address = ip_address
93
+
94
+ def to_dict(self):
95
+ """Returns the model properties as a dict"""
96
+ result = {}
97
+
98
+ for attr, _ in six.iteritems(self.openapi_types):
99
+ value = getattr(self, attr)
100
+ if isinstance(value, list):
101
+ result[attr] = list(map(
102
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
103
+ value
104
+ ))
105
+ elif hasattr(value, "to_dict"):
106
+ result[attr] = value.to_dict()
107
+ elif isinstance(value, dict):
108
+ result[attr] = dict(map(
109
+ lambda item: (item[0], item[1].to_dict())
110
+ if hasattr(item[1], "to_dict") else item,
111
+ value.items()
112
+ ))
113
+ else:
114
+ if attr in self.sensitive_list:
115
+ result[attr] = "****"
116
+ else:
117
+ result[attr] = value
118
+
119
+ return result
120
+
121
+ def to_str(self):
122
+ """Returns the string representation of the model"""
123
+ import simplejson as json
124
+ if six.PY2:
125
+ import sys
126
+ reload(sys)
127
+ sys.setdefaultencoding("utf-8")
128
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
129
+
130
+ def __repr__(self):
131
+ """For `print`"""
132
+ return self.to_str()
133
+
134
+ def __eq__(self, other):
135
+ """Returns true if both objects are equal"""
136
+ if not isinstance(other, ModifyInstanceIpRequestBodyNics):
137
+ return False
138
+
139
+ return self.__dict__ == other.__dict__
140
+
141
+ def __ne__(self, other):
142
+ """Returns true if both objects are not equal"""
143
+ return not self == other
@@ -0,0 +1,85 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.sdk_response import SdkResponse
6
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
7
+
8
+
9
+ class ModifyInstanceIpResponse(SdkResponse):
10
+
11
+ """
12
+ Attributes:
13
+ openapi_types (dict): The key is attribute name
14
+ and the value is attribute type.
15
+ attribute_map (dict): The key is attribute name
16
+ and the value is json key in definition.
17
+ """
18
+ sensitive_list = []
19
+
20
+ openapi_types = {
21
+ }
22
+
23
+ attribute_map = {
24
+ }
25
+
26
+ def __init__(self):
27
+ r"""ModifyInstanceIpResponse
28
+
29
+ The model defined in huaweicloud sdk
30
+
31
+ """
32
+
33
+ super(ModifyInstanceIpResponse, self).__init__()
34
+ self.discriminator = None
35
+
36
+ def to_dict(self):
37
+ """Returns the model properties as a dict"""
38
+ result = {}
39
+
40
+ for attr, _ in six.iteritems(self.openapi_types):
41
+ value = getattr(self, attr)
42
+ if isinstance(value, list):
43
+ result[attr] = list(map(
44
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
45
+ value
46
+ ))
47
+ elif hasattr(value, "to_dict"):
48
+ result[attr] = value.to_dict()
49
+ elif isinstance(value, dict):
50
+ result[attr] = dict(map(
51
+ lambda item: (item[0], item[1].to_dict())
52
+ if hasattr(item[1], "to_dict") else item,
53
+ value.items()
54
+ ))
55
+ else:
56
+ if attr in self.sensitive_list:
57
+ result[attr] = "****"
58
+ else:
59
+ result[attr] = value
60
+
61
+ return result
62
+
63
+ def to_str(self):
64
+ """Returns the string representation of the model"""
65
+ import simplejson as json
66
+ if six.PY2:
67
+ import sys
68
+ reload(sys)
69
+ sys.setdefaultencoding("utf-8")
70
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
71
+
72
+ def __repr__(self):
73
+ """For `print`"""
74
+ return self.to_str()
75
+
76
+ def __eq__(self, other):
77
+ """Returns true if both objects are equal"""
78
+ if not isinstance(other, ModifyInstanceIpResponse):
79
+ return False
80
+
81
+ return self.__dict__ == other.__dict__
82
+
83
+ def __ne__(self, other):
84
+ """Returns true if both objects are not equal"""
85
+ return not self == other