huaweicloudsdkworkspace 3.1.123__py2.py3-none-any.whl → 3.1.124__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 huaweicloudsdkworkspace might be problematic. Click here for more details.

Files changed (63) hide show
  1. huaweicloudsdkworkspace/v2/__init__.py +54 -0
  2. huaweicloudsdkworkspace/v2/model/__init__.py +54 -0
  3. huaweicloudsdkworkspace/v2/model/add_desktop_pool_volumes_req.py +144 -0
  4. huaweicloudsdkworkspace/v2/model/add_desktop_pool_volumes_request.py +168 -0
  5. huaweicloudsdkworkspace/v2/model/add_desktop_pool_volumes_response.py +319 -0
  6. huaweicloudsdkworkspace/v2/model/authorized_objects.py +227 -0
  7. huaweicloudsdkworkspace/v2/model/autoscale_policy.py +202 -0
  8. huaweicloudsdkworkspace/v2/model/base_error.py +144 -0
  9. huaweicloudsdkworkspace/v2/model/batch_delete_user_req.py +114 -0
  10. huaweicloudsdkworkspace/v2/model/batch_delete_user_request.py +111 -0
  11. huaweicloudsdkworkspace/v2/model/batch_delete_user_response.py +85 -0
  12. huaweicloudsdkworkspace/v2/model/cbc_callback_rsp.py +289 -0
  13. huaweicloudsdkworkspace/v2/model/create_desktop_pool_authorized_objects_request.py +139 -0
  14. huaweicloudsdkworkspace/v2/model/create_desktop_pool_authorized_objects_request_body.py +143 -0
  15. huaweicloudsdkworkspace/v2/model/create_desktop_pool_authorized_objects_response.py +85 -0
  16. huaweicloudsdkworkspace/v2/model/create_desktop_pool_req.py +708 -0
  17. huaweicloudsdkworkspace/v2/model/create_desktop_pool_request.py +140 -0
  18. huaweicloudsdkworkspace/v2/model/create_desktop_pool_response.py +116 -0
  19. huaweicloudsdkworkspace/v2/model/create_desktop_rsp.py +115 -0
  20. huaweicloudsdkworkspace/v2/model/delete_desktop_pool_request.py +114 -0
  21. huaweicloudsdkworkspace/v2/model/delete_desktop_pool_response.py +85 -0
  22. huaweicloudsdkworkspace/v2/model/delete_desktop_pool_volumes_req.py +115 -0
  23. huaweicloudsdkworkspace/v2/model/delete_desktop_pool_volumes_request.py +139 -0
  24. huaweicloudsdkworkspace/v2/model/delete_desktop_pool_volumes_response.py +116 -0
  25. huaweicloudsdkworkspace/v2/model/desktop_pool_action_req.py +143 -0
  26. huaweicloudsdkworkspace/v2/model/execute_desktop_pool_action_request.py +139 -0
  27. huaweicloudsdkworkspace/v2/model/execute_desktop_pool_action_response.py +116 -0
  28. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_req.py +143 -0
  29. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_request.py +168 -0
  30. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_response.py +116 -0
  31. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_volumes_req.py +144 -0
  32. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_volumes_request.py +168 -0
  33. huaweicloudsdkworkspace/v2/model/expand_desktop_pool_volumes_response.py +319 -0
  34. huaweicloudsdkworkspace/v2/model/list_desktop_pool_authorized_objects_request.py +172 -0
  35. huaweicloudsdkworkspace/v2/model/list_desktop_pool_authorized_objects_response.py +145 -0
  36. huaweicloudsdkworkspace/v2/model/list_desktop_pools_request.py +260 -0
  37. huaweicloudsdkworkspace/v2/model/list_desktop_pools_response.py +145 -0
  38. huaweicloudsdkworkspace/v2/model/list_pool_desktops_detail_request.py +201 -0
  39. huaweicloudsdkworkspace/v2/model/list_pool_desktops_detail_response.py +203 -0
  40. huaweicloudsdkworkspace/v2/model/pool_desktops_detail_info.py +1147 -0
  41. huaweicloudsdkworkspace/v2/model/rebuild_desktop_pool_req.py +288 -0
  42. huaweicloudsdkworkspace/v2/model/rebuild_desktop_pool_request.py +168 -0
  43. huaweicloudsdkworkspace/v2/model/rebuild_desktop_pool_response.py +232 -0
  44. huaweicloudsdkworkspace/v2/model/resize_desktop_extend_param.py +115 -0
  45. huaweicloudsdkworkspace/v2/model/resize_desktop_pool_job_response.py +144 -0
  46. huaweicloudsdkworkspace/v2/model/resize_desktop_pool_req.py +197 -0
  47. huaweicloudsdkworkspace/v2/model/resize_desktop_pool_request.py +168 -0
  48. huaweicloudsdkworkspace/v2/model/resize_desktop_pool_response.py +174 -0
  49. huaweicloudsdkworkspace/v2/model/show_desktop_pool_detail_request.py +114 -0
  50. huaweicloudsdkworkspace/v2/model/show_desktop_pool_detail_response.py +887 -0
  51. huaweicloudsdkworkspace/v2/model/simple_desktop_pool_info.py +886 -0
  52. huaweicloudsdkworkspace/v2/model/update_desktop_pool_attributes_req.py +372 -0
  53. huaweicloudsdkworkspace/v2/model/update_desktop_pool_request.py +139 -0
  54. huaweicloudsdkworkspace/v2/model/update_desktop_pool_response.py +85 -0
  55. huaweicloudsdkworkspace/v2/model/volume_add_info.py +200 -0
  56. huaweicloudsdkworkspace/v2/model/volume_info.py +229 -0
  57. huaweicloudsdkworkspace/v2/workspace_async_client.py +1091 -0
  58. huaweicloudsdkworkspace/v2/workspace_client.py +1091 -0
  59. {huaweicloudsdkworkspace-3.1.123.dist-info → huaweicloudsdkworkspace-3.1.124.dist-info}/METADATA +2 -2
  60. {huaweicloudsdkworkspace-3.1.123.dist-info → huaweicloudsdkworkspace-3.1.124.dist-info}/RECORD +63 -9
  61. {huaweicloudsdkworkspace-3.1.123.dist-info → huaweicloudsdkworkspace-3.1.124.dist-info}/WHEEL +1 -1
  62. {huaweicloudsdkworkspace-3.1.123.dist-info → huaweicloudsdkworkspace-3.1.124.dist-info}/LICENSE +0 -0
  63. {huaweicloudsdkworkspace-3.1.123.dist-info → huaweicloudsdkworkspace-3.1.124.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,372 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class UpdateDesktopPoolAttributesReq:
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
+ 'name': 'str',
21
+ 'description': 'str',
22
+ 'ou_name': 'str',
23
+ 'tags': 'list[Tag]',
24
+ 'disconnected_retention_period': 'int',
25
+ 'enable_autoscale': 'bool',
26
+ 'autoscale_policy': 'AutoscalePolicy',
27
+ 'in_maintenance_mode': 'bool',
28
+ 'desktop_name_policy_id': 'str',
29
+ 'availability_zone': 'str'
30
+ }
31
+
32
+ attribute_map = {
33
+ 'name': 'name',
34
+ 'description': 'description',
35
+ 'ou_name': 'ou_name',
36
+ 'tags': 'tags',
37
+ 'disconnected_retention_period': 'disconnected_retention_period',
38
+ 'enable_autoscale': 'enable_autoscale',
39
+ 'autoscale_policy': 'autoscale_policy',
40
+ 'in_maintenance_mode': 'in_maintenance_mode',
41
+ 'desktop_name_policy_id': 'desktop_name_policy_id',
42
+ 'availability_zone': 'availability_zone'
43
+ }
44
+
45
+ def __init__(self, name=None, description=None, ou_name=None, tags=None, disconnected_retention_period=None, enable_autoscale=None, autoscale_policy=None, in_maintenance_mode=None, desktop_name_policy_id=None, availability_zone=None):
46
+ """UpdateDesktopPoolAttributesReq
47
+
48
+ The model defined in huaweicloud sdk
49
+
50
+ :param name: 桌面池名称,桌面池名称必须保证唯一。桌面名称只允许输入中文、大写字母、小写字母、数字、中划线,长度范围为1~255。
51
+ :type name: str
52
+ :param description: 桌面池描述。
53
+ :type description: str
54
+ :param ou_name: OU名称,在对接AD时使用,需提前在AD中创建OU。
55
+ :type ou_name: str
56
+ :param tags: 标签列表。
57
+ :type tags: list[:class:`huaweicloudsdkworkspace.v2.Tag`]
58
+ :param disconnected_retention_period: 桌面断连多少分钟内,保留用户与桌面的绑定关系,超时后自动解绑。
59
+ :type disconnected_retention_period: int
60
+ :param enable_autoscale: 桌面池是否开启弹性伸缩类型,为false则表示不开启弹性伸缩,为true则表示开启弹性伸缩。
61
+ :type enable_autoscale: bool
62
+ :param autoscale_policy:
63
+ :type autoscale_policy: :class:`huaweicloudsdkworkspace.v2.AutoscalePolicy`
64
+ :param in_maintenance_mode: 是否处于管理员维护模式
65
+ :type in_maintenance_mode: bool
66
+ :param desktop_name_policy_id: 策略id,用于指定生成桌面名称策略。
67
+ :type desktop_name_policy_id: str
68
+ :param availability_zone: 桌面池的可用区。
69
+ :type availability_zone: str
70
+ """
71
+
72
+
73
+
74
+ self._name = None
75
+ self._description = None
76
+ self._ou_name = None
77
+ self._tags = None
78
+ self._disconnected_retention_period = None
79
+ self._enable_autoscale = None
80
+ self._autoscale_policy = None
81
+ self._in_maintenance_mode = None
82
+ self._desktop_name_policy_id = None
83
+ self._availability_zone = None
84
+ self.discriminator = None
85
+
86
+ if name is not None:
87
+ self.name = name
88
+ if description is not None:
89
+ self.description = description
90
+ if ou_name is not None:
91
+ self.ou_name = ou_name
92
+ if tags is not None:
93
+ self.tags = tags
94
+ if disconnected_retention_period is not None:
95
+ self.disconnected_retention_period = disconnected_retention_period
96
+ if enable_autoscale is not None:
97
+ self.enable_autoscale = enable_autoscale
98
+ if autoscale_policy is not None:
99
+ self.autoscale_policy = autoscale_policy
100
+ if in_maintenance_mode is not None:
101
+ self.in_maintenance_mode = in_maintenance_mode
102
+ if desktop_name_policy_id is not None:
103
+ self.desktop_name_policy_id = desktop_name_policy_id
104
+ if availability_zone is not None:
105
+ self.availability_zone = availability_zone
106
+
107
+ @property
108
+ def name(self):
109
+ """Gets the name of this UpdateDesktopPoolAttributesReq.
110
+
111
+ 桌面池名称,桌面池名称必须保证唯一。桌面名称只允许输入中文、大写字母、小写字母、数字、中划线,长度范围为1~255。
112
+
113
+ :return: The name of this UpdateDesktopPoolAttributesReq.
114
+ :rtype: str
115
+ """
116
+ return self._name
117
+
118
+ @name.setter
119
+ def name(self, name):
120
+ """Sets the name of this UpdateDesktopPoolAttributesReq.
121
+
122
+ 桌面池名称,桌面池名称必须保证唯一。桌面名称只允许输入中文、大写字母、小写字母、数字、中划线,长度范围为1~255。
123
+
124
+ :param name: The name of this UpdateDesktopPoolAttributesReq.
125
+ :type name: str
126
+ """
127
+ self._name = name
128
+
129
+ @property
130
+ def description(self):
131
+ """Gets the description of this UpdateDesktopPoolAttributesReq.
132
+
133
+ 桌面池描述。
134
+
135
+ :return: The description of this UpdateDesktopPoolAttributesReq.
136
+ :rtype: str
137
+ """
138
+ return self._description
139
+
140
+ @description.setter
141
+ def description(self, description):
142
+ """Sets the description of this UpdateDesktopPoolAttributesReq.
143
+
144
+ 桌面池描述。
145
+
146
+ :param description: The description of this UpdateDesktopPoolAttributesReq.
147
+ :type description: str
148
+ """
149
+ self._description = description
150
+
151
+ @property
152
+ def ou_name(self):
153
+ """Gets the ou_name of this UpdateDesktopPoolAttributesReq.
154
+
155
+ OU名称,在对接AD时使用,需提前在AD中创建OU。
156
+
157
+ :return: The ou_name of this UpdateDesktopPoolAttributesReq.
158
+ :rtype: str
159
+ """
160
+ return self._ou_name
161
+
162
+ @ou_name.setter
163
+ def ou_name(self, ou_name):
164
+ """Sets the ou_name of this UpdateDesktopPoolAttributesReq.
165
+
166
+ OU名称,在对接AD时使用,需提前在AD中创建OU。
167
+
168
+ :param ou_name: The ou_name of this UpdateDesktopPoolAttributesReq.
169
+ :type ou_name: str
170
+ """
171
+ self._ou_name = ou_name
172
+
173
+ @property
174
+ def tags(self):
175
+ """Gets the tags of this UpdateDesktopPoolAttributesReq.
176
+
177
+ 标签列表。
178
+
179
+ :return: The tags of this UpdateDesktopPoolAttributesReq.
180
+ :rtype: list[:class:`huaweicloudsdkworkspace.v2.Tag`]
181
+ """
182
+ return self._tags
183
+
184
+ @tags.setter
185
+ def tags(self, tags):
186
+ """Sets the tags of this UpdateDesktopPoolAttributesReq.
187
+
188
+ 标签列表。
189
+
190
+ :param tags: The tags of this UpdateDesktopPoolAttributesReq.
191
+ :type tags: list[:class:`huaweicloudsdkworkspace.v2.Tag`]
192
+ """
193
+ self._tags = tags
194
+
195
+ @property
196
+ def disconnected_retention_period(self):
197
+ """Gets the disconnected_retention_period of this UpdateDesktopPoolAttributesReq.
198
+
199
+ 桌面断连多少分钟内,保留用户与桌面的绑定关系,超时后自动解绑。
200
+
201
+ :return: The disconnected_retention_period of this UpdateDesktopPoolAttributesReq.
202
+ :rtype: int
203
+ """
204
+ return self._disconnected_retention_period
205
+
206
+ @disconnected_retention_period.setter
207
+ def disconnected_retention_period(self, disconnected_retention_period):
208
+ """Sets the disconnected_retention_period of this UpdateDesktopPoolAttributesReq.
209
+
210
+ 桌面断连多少分钟内,保留用户与桌面的绑定关系,超时后自动解绑。
211
+
212
+ :param disconnected_retention_period: The disconnected_retention_period of this UpdateDesktopPoolAttributesReq.
213
+ :type disconnected_retention_period: int
214
+ """
215
+ self._disconnected_retention_period = disconnected_retention_period
216
+
217
+ @property
218
+ def enable_autoscale(self):
219
+ """Gets the enable_autoscale of this UpdateDesktopPoolAttributesReq.
220
+
221
+ 桌面池是否开启弹性伸缩类型,为false则表示不开启弹性伸缩,为true则表示开启弹性伸缩。
222
+
223
+ :return: The enable_autoscale of this UpdateDesktopPoolAttributesReq.
224
+ :rtype: bool
225
+ """
226
+ return self._enable_autoscale
227
+
228
+ @enable_autoscale.setter
229
+ def enable_autoscale(self, enable_autoscale):
230
+ """Sets the enable_autoscale of this UpdateDesktopPoolAttributesReq.
231
+
232
+ 桌面池是否开启弹性伸缩类型,为false则表示不开启弹性伸缩,为true则表示开启弹性伸缩。
233
+
234
+ :param enable_autoscale: The enable_autoscale of this UpdateDesktopPoolAttributesReq.
235
+ :type enable_autoscale: bool
236
+ """
237
+ self._enable_autoscale = enable_autoscale
238
+
239
+ @property
240
+ def autoscale_policy(self):
241
+ """Gets the autoscale_policy of this UpdateDesktopPoolAttributesReq.
242
+
243
+ :return: The autoscale_policy of this UpdateDesktopPoolAttributesReq.
244
+ :rtype: :class:`huaweicloudsdkworkspace.v2.AutoscalePolicy`
245
+ """
246
+ return self._autoscale_policy
247
+
248
+ @autoscale_policy.setter
249
+ def autoscale_policy(self, autoscale_policy):
250
+ """Sets the autoscale_policy of this UpdateDesktopPoolAttributesReq.
251
+
252
+ :param autoscale_policy: The autoscale_policy of this UpdateDesktopPoolAttributesReq.
253
+ :type autoscale_policy: :class:`huaweicloudsdkworkspace.v2.AutoscalePolicy`
254
+ """
255
+ self._autoscale_policy = autoscale_policy
256
+
257
+ @property
258
+ def in_maintenance_mode(self):
259
+ """Gets the in_maintenance_mode of this UpdateDesktopPoolAttributesReq.
260
+
261
+ 是否处于管理员维护模式
262
+
263
+ :return: The in_maintenance_mode of this UpdateDesktopPoolAttributesReq.
264
+ :rtype: bool
265
+ """
266
+ return self._in_maintenance_mode
267
+
268
+ @in_maintenance_mode.setter
269
+ def in_maintenance_mode(self, in_maintenance_mode):
270
+ """Sets the in_maintenance_mode of this UpdateDesktopPoolAttributesReq.
271
+
272
+ 是否处于管理员维护模式
273
+
274
+ :param in_maintenance_mode: The in_maintenance_mode of this UpdateDesktopPoolAttributesReq.
275
+ :type in_maintenance_mode: bool
276
+ """
277
+ self._in_maintenance_mode = in_maintenance_mode
278
+
279
+ @property
280
+ def desktop_name_policy_id(self):
281
+ """Gets the desktop_name_policy_id of this UpdateDesktopPoolAttributesReq.
282
+
283
+ 策略id,用于指定生成桌面名称策略。
284
+
285
+ :return: The desktop_name_policy_id of this UpdateDesktopPoolAttributesReq.
286
+ :rtype: str
287
+ """
288
+ return self._desktop_name_policy_id
289
+
290
+ @desktop_name_policy_id.setter
291
+ def desktop_name_policy_id(self, desktop_name_policy_id):
292
+ """Sets the desktop_name_policy_id of this UpdateDesktopPoolAttributesReq.
293
+
294
+ 策略id,用于指定生成桌面名称策略。
295
+
296
+ :param desktop_name_policy_id: The desktop_name_policy_id of this UpdateDesktopPoolAttributesReq.
297
+ :type desktop_name_policy_id: str
298
+ """
299
+ self._desktop_name_policy_id = desktop_name_policy_id
300
+
301
+ @property
302
+ def availability_zone(self):
303
+ """Gets the availability_zone of this UpdateDesktopPoolAttributesReq.
304
+
305
+ 桌面池的可用区。
306
+
307
+ :return: The availability_zone of this UpdateDesktopPoolAttributesReq.
308
+ :rtype: str
309
+ """
310
+ return self._availability_zone
311
+
312
+ @availability_zone.setter
313
+ def availability_zone(self, availability_zone):
314
+ """Sets the availability_zone of this UpdateDesktopPoolAttributesReq.
315
+
316
+ 桌面池的可用区。
317
+
318
+ :param availability_zone: The availability_zone of this UpdateDesktopPoolAttributesReq.
319
+ :type availability_zone: str
320
+ """
321
+ self._availability_zone = availability_zone
322
+
323
+ def to_dict(self):
324
+ """Returns the model properties as a dict"""
325
+ result = {}
326
+
327
+ for attr, _ in six.iteritems(self.openapi_types):
328
+ value = getattr(self, attr)
329
+ if isinstance(value, list):
330
+ result[attr] = list(map(
331
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
332
+ value
333
+ ))
334
+ elif hasattr(value, "to_dict"):
335
+ result[attr] = value.to_dict()
336
+ elif isinstance(value, dict):
337
+ result[attr] = dict(map(
338
+ lambda item: (item[0], item[1].to_dict())
339
+ if hasattr(item[1], "to_dict") else item,
340
+ value.items()
341
+ ))
342
+ else:
343
+ if attr in self.sensitive_list:
344
+ result[attr] = "****"
345
+ else:
346
+ result[attr] = value
347
+
348
+ return result
349
+
350
+ def to_str(self):
351
+ """Returns the string representation of the model"""
352
+ import simplejson as json
353
+ if six.PY2:
354
+ import sys
355
+ reload(sys)
356
+ sys.setdefaultencoding("utf-8")
357
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
358
+
359
+ def __repr__(self):
360
+ """For `print`"""
361
+ return self.to_str()
362
+
363
+ def __eq__(self, other):
364
+ """Returns true if both objects are equal"""
365
+ if not isinstance(other, UpdateDesktopPoolAttributesReq):
366
+ return False
367
+
368
+ return self.__dict__ == other.__dict__
369
+
370
+ def __ne__(self, other):
371
+ """Returns true if both objects are not equal"""
372
+ 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 UpdateDesktopPoolRequest:
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
+ 'pool_id': 'str',
21
+ 'body': 'UpdateDesktopPoolAttributesReq'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'pool_id': 'pool_id',
26
+ 'body': 'body'
27
+ }
28
+
29
+ def __init__(self, pool_id=None, body=None):
30
+ """UpdateDesktopPoolRequest
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param pool_id: 桌面池ID。
35
+ :type pool_id: str
36
+ :param body: Body of the UpdateDesktopPoolRequest
37
+ :type body: :class:`huaweicloudsdkworkspace.v2.UpdateDesktopPoolAttributesReq`
38
+ """
39
+
40
+
41
+
42
+ self._pool_id = None
43
+ self._body = None
44
+ self.discriminator = None
45
+
46
+ self.pool_id = pool_id
47
+ if body is not None:
48
+ self.body = body
49
+
50
+ @property
51
+ def pool_id(self):
52
+ """Gets the pool_id of this UpdateDesktopPoolRequest.
53
+
54
+ 桌面池ID。
55
+
56
+ :return: The pool_id of this UpdateDesktopPoolRequest.
57
+ :rtype: str
58
+ """
59
+ return self._pool_id
60
+
61
+ @pool_id.setter
62
+ def pool_id(self, pool_id):
63
+ """Sets the pool_id of this UpdateDesktopPoolRequest.
64
+
65
+ 桌面池ID。
66
+
67
+ :param pool_id: The pool_id of this UpdateDesktopPoolRequest.
68
+ :type pool_id: str
69
+ """
70
+ self._pool_id = pool_id
71
+
72
+ @property
73
+ def body(self):
74
+ """Gets the body of this UpdateDesktopPoolRequest.
75
+
76
+ :return: The body of this UpdateDesktopPoolRequest.
77
+ :rtype: :class:`huaweicloudsdkworkspace.v2.UpdateDesktopPoolAttributesReq`
78
+ """
79
+ return self._body
80
+
81
+ @body.setter
82
+ def body(self, body):
83
+ """Sets the body of this UpdateDesktopPoolRequest.
84
+
85
+ :param body: The body of this UpdateDesktopPoolRequest.
86
+ :type body: :class:`huaweicloudsdkworkspace.v2.UpdateDesktopPoolAttributesReq`
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, UpdateDesktopPoolRequest):
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,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 UpdateDesktopPoolResponse(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
+ """UpdateDesktopPoolResponse
28
+
29
+ The model defined in huaweicloud sdk
30
+
31
+ """
32
+
33
+ super(UpdateDesktopPoolResponse, 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, UpdateDesktopPoolResponse):
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