huaweicloudsdkobs 3.1.160__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.
- huaweicloudsdkobs/__init__.py +0 -0
- huaweicloudsdkobs/v1/__init__.py +66 -0
- huaweicloudsdkobs/v1/model/__init__.py +63 -0
- huaweicloudsdkobs/v1/model/access_control_list.py +113 -0
- huaweicloudsdkobs/v1/model/bucket.py +233 -0
- huaweicloudsdkobs/v1/model/buckets.py +117 -0
- huaweicloudsdkobs/v1/model/common_prefixes.py +113 -0
- huaweicloudsdkobs/v1/model/contents.py +287 -0
- huaweicloudsdkobs/v1/model/copy_object_request.py +839 -0
- huaweicloudsdkobs/v1/model/copy_object_response.py +443 -0
- huaweicloudsdkobs/v1/model/create_bucket_request.py +605 -0
- huaweicloudsdkobs/v1/model/create_bucket_request_body.py +117 -0
- huaweicloudsdkobs/v1/model/create_bucket_response.py +239 -0
- huaweicloudsdkobs/v1/model/delete_bucket_customdomain_request.py +173 -0
- huaweicloudsdkobs/v1/model/delete_bucket_customdomain_response.py +239 -0
- huaweicloudsdkobs/v1/model/delete_bucket_request.py +145 -0
- huaweicloudsdkobs/v1/model/delete_bucket_response.py +239 -0
- huaweicloudsdkobs/v1/model/delete_object.py +146 -0
- huaweicloudsdkobs/v1/model/delete_object_request.py +202 -0
- huaweicloudsdkobs/v1/model/delete_object_response.py +289 -0
- huaweicloudsdkobs/v1/model/delete_objects_request.py +226 -0
- huaweicloudsdkobs/v1/model/delete_objects_request_body.py +171 -0
- huaweicloudsdkobs/v1/model/delete_objects_response.py +318 -0
- huaweicloudsdkobs/v1/model/delete_result_deleted.py +204 -0
- huaweicloudsdkobs/v1/model/delete_result_error.py +175 -0
- huaweicloudsdkobs/v1/model/domains.py +173 -0
- huaweicloudsdkobs/v1/model/filter_object.py +113 -0
- huaweicloudsdkobs/v1/model/filter_rule.py +146 -0
- huaweicloudsdkobs/v1/model/function_stage_configuration.py +229 -0
- huaweicloudsdkobs/v1/model/get_bucket_acl_request.py +173 -0
- huaweicloudsdkobs/v1/model/get_bucket_acl_response.py +289 -0
- huaweicloudsdkobs/v1/model/get_bucket_customdomain_request.py +173 -0
- huaweicloudsdkobs/v1/model/get_bucket_customdomain_response.py +264 -0
- huaweicloudsdkobs/v1/model/get_bucket_metadata_request.py +203 -0
- huaweicloudsdkobs/v1/model/get_bucket_metadata_response.py +539 -0
- huaweicloudsdkobs/v1/model/get_bucket_notification_request.py +173 -0
- huaweicloudsdkobs/v1/model/get_bucket_notification_response.py +264 -0
- huaweicloudsdkobs/v1/model/get_object_metadata_request.py +405 -0
- huaweicloudsdkobs/v1/model/get_object_metadata_response.py +689 -0
- huaweicloudsdkobs/v1/model/get_object_request.py +666 -0
- huaweicloudsdkobs/v1/model/get_object_response.py +489 -0
- huaweicloudsdkobs/v1/model/grant.py +171 -0
- huaweicloudsdkobs/v1/model/grantee.py +146 -0
- huaweicloudsdkobs/v1/model/list_buckets_request.py +146 -0
- huaweicloudsdkobs/v1/model/list_buckets_response.py +314 -0
- huaweicloudsdkobs/v1/model/list_objects_request.py +348 -0
- huaweicloudsdkobs/v1/model/list_objects_response.py +546 -0
- huaweicloudsdkobs/v1/model/owner.py +117 -0
- huaweicloudsdkobs/v1/model/put_object_request.py +667 -0
- huaweicloudsdkobs/v1/model/put_object_response.py +389 -0
- huaweicloudsdkobs/v1/model/set_bucket_acl_request.py +227 -0
- huaweicloudsdkobs/v1/model/set_bucket_acl_request_body.py +138 -0
- huaweicloudsdkobs/v1/model/set_bucket_acl_response.py +239 -0
- huaweicloudsdkobs/v1/model/set_bucket_custom_domain_body.py +230 -0
- huaweicloudsdkobs/v1/model/set_bucket_customedomain_request.py +198 -0
- huaweicloudsdkobs/v1/model/set_bucket_customedomain_response.py +239 -0
- huaweicloudsdkobs/v1/model/set_bucket_notification_request.py +198 -0
- huaweicloudsdkobs/v1/model/set_bucket_notification_request_body.py +138 -0
- huaweicloudsdkobs/v1/model/set_bucket_notification_response.py +239 -0
- huaweicloudsdkobs/v1/model/topic_configuration.py +200 -0
- huaweicloudsdkobs/v1/model/topic_configuration_filter.py +113 -0
- huaweicloudsdkobs/v1/obs_async_client.py +1600 -0
- huaweicloudsdkobs/v1/obs_client.py +1597 -0
- huaweicloudsdkobs/v1/obs_credentials.py +69 -0
- huaweicloudsdkobs/v1/obs_signer.py +298 -0
- huaweicloudsdkobs/v1/region/__init__.py +0 -0
- huaweicloudsdkobs/v1/region/obs_region.py +88 -0
- huaweicloudsdkobs-3.1.160.dist-info/LICENSE +13 -0
- huaweicloudsdkobs-3.1.160.dist-info/METADATA +26 -0
- huaweicloudsdkobs-3.1.160.dist-info/RECORD +72 -0
- huaweicloudsdkobs-3.1.160.dist-info/WHEEL +5 -0
- huaweicloudsdkobs-3.1.160.dist-info/top_level.txt +1 -0
@@ -0,0 +1,389 @@
|
|
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 PutObjectResponse(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
|
+
xml_name = "PutObjectResponse"
|
19
|
+
|
20
|
+
sensitive_list = []
|
21
|
+
|
22
|
+
openapi_types = {
|
23
|
+
'x_obs_id_2': 'str',
|
24
|
+
'x_obs_request_id': 'str',
|
25
|
+
'e_tag': 'str',
|
26
|
+
'x_obs_server_side_encryption': 'str',
|
27
|
+
'x_obs_server_side_encryption_customer_algorithm': 'str',
|
28
|
+
'x_obs_storage_class': 'str',
|
29
|
+
'connection': 'str',
|
30
|
+
'x_obs_server_side_encryption_customer_key_md5': 'str',
|
31
|
+
'x_obs_server_side_encryption_kms_key_id': 'str',
|
32
|
+
'content_length': 'str',
|
33
|
+
'date': 'str',
|
34
|
+
'x_obs_version_id': 'str'
|
35
|
+
}
|
36
|
+
|
37
|
+
attribute_map = {
|
38
|
+
'x_obs_id_2': 'x-obs-id-2',
|
39
|
+
'x_obs_request_id': 'x-obs-request-id',
|
40
|
+
'e_tag': 'ETag',
|
41
|
+
'x_obs_server_side_encryption': 'x-obs-server-side-encryption',
|
42
|
+
'x_obs_server_side_encryption_customer_algorithm': 'x-obs-server-side-encryption-customer-algorithm',
|
43
|
+
'x_obs_storage_class': 'x-obs-storage-class',
|
44
|
+
'connection': 'Connection',
|
45
|
+
'x_obs_server_side_encryption_customer_key_md5': 'x-obs-server-side-encryption-customer-key-MD5',
|
46
|
+
'x_obs_server_side_encryption_kms_key_id': 'x-obs-server-side-encryption-kms-key-id',
|
47
|
+
'content_length': 'Content-Length',
|
48
|
+
'date': 'Date',
|
49
|
+
'x_obs_version_id': 'x-obs-version-id'
|
50
|
+
}
|
51
|
+
|
52
|
+
def __init__(self, x_obs_id_2=None, x_obs_request_id=None, e_tag=None, x_obs_server_side_encryption=None, x_obs_server_side_encryption_customer_algorithm=None, x_obs_storage_class=None, connection=None, x_obs_server_side_encryption_customer_key_md5=None, x_obs_server_side_encryption_kms_key_id=None, content_length=None, date=None, x_obs_version_id=None):
|
53
|
+
r"""PutObjectResponse
|
54
|
+
|
55
|
+
The model defined in huaweicloud sdk
|
56
|
+
|
57
|
+
:param x_obs_id_2:
|
58
|
+
:type x_obs_id_2: str
|
59
|
+
:param x_obs_request_id:
|
60
|
+
:type x_obs_request_id: str
|
61
|
+
:param e_tag:
|
62
|
+
:type e_tag: str
|
63
|
+
:param x_obs_server_side_encryption:
|
64
|
+
:type x_obs_server_side_encryption: str
|
65
|
+
:param x_obs_server_side_encryption_customer_algorithm:
|
66
|
+
:type x_obs_server_side_encryption_customer_algorithm: str
|
67
|
+
:param x_obs_storage_class:
|
68
|
+
:type x_obs_storage_class: str
|
69
|
+
:param connection:
|
70
|
+
:type connection: str
|
71
|
+
:param x_obs_server_side_encryption_customer_key_md5:
|
72
|
+
:type x_obs_server_side_encryption_customer_key_md5: str
|
73
|
+
:param x_obs_server_side_encryption_kms_key_id:
|
74
|
+
:type x_obs_server_side_encryption_kms_key_id: str
|
75
|
+
:param content_length:
|
76
|
+
:type content_length: str
|
77
|
+
:param date:
|
78
|
+
:type date: str
|
79
|
+
:param x_obs_version_id:
|
80
|
+
:type x_obs_version_id: str
|
81
|
+
"""
|
82
|
+
|
83
|
+
super(PutObjectResponse, self).__init__()
|
84
|
+
|
85
|
+
self._x_obs_id_2 = None
|
86
|
+
self._x_obs_request_id = None
|
87
|
+
self._e_tag = None
|
88
|
+
self._x_obs_server_side_encryption = None
|
89
|
+
self._x_obs_server_side_encryption_customer_algorithm = None
|
90
|
+
self._x_obs_storage_class = None
|
91
|
+
self._connection = None
|
92
|
+
self._x_obs_server_side_encryption_customer_key_md5 = None
|
93
|
+
self._x_obs_server_side_encryption_kms_key_id = None
|
94
|
+
self._content_length = None
|
95
|
+
self._date = None
|
96
|
+
self._x_obs_version_id = None
|
97
|
+
self.discriminator = None
|
98
|
+
|
99
|
+
if x_obs_id_2 is not None:
|
100
|
+
self.x_obs_id_2 = x_obs_id_2
|
101
|
+
if x_obs_request_id is not None:
|
102
|
+
self.x_obs_request_id = x_obs_request_id
|
103
|
+
if e_tag is not None:
|
104
|
+
self.e_tag = e_tag
|
105
|
+
if x_obs_server_side_encryption is not None:
|
106
|
+
self.x_obs_server_side_encryption = x_obs_server_side_encryption
|
107
|
+
if x_obs_server_side_encryption_customer_algorithm is not None:
|
108
|
+
self.x_obs_server_side_encryption_customer_algorithm = x_obs_server_side_encryption_customer_algorithm
|
109
|
+
if x_obs_storage_class is not None:
|
110
|
+
self.x_obs_storage_class = x_obs_storage_class
|
111
|
+
if connection is not None:
|
112
|
+
self.connection = connection
|
113
|
+
if x_obs_server_side_encryption_customer_key_md5 is not None:
|
114
|
+
self.x_obs_server_side_encryption_customer_key_md5 = x_obs_server_side_encryption_customer_key_md5
|
115
|
+
if x_obs_server_side_encryption_kms_key_id is not None:
|
116
|
+
self.x_obs_server_side_encryption_kms_key_id = x_obs_server_side_encryption_kms_key_id
|
117
|
+
if content_length is not None:
|
118
|
+
self.content_length = content_length
|
119
|
+
if date is not None:
|
120
|
+
self.date = date
|
121
|
+
if x_obs_version_id is not None:
|
122
|
+
self.x_obs_version_id = x_obs_version_id
|
123
|
+
|
124
|
+
@property
|
125
|
+
def x_obs_id_2(self):
|
126
|
+
r"""Gets the x_obs_id_2 of this PutObjectResponse.
|
127
|
+
|
128
|
+
:return: The x_obs_id_2 of this PutObjectResponse.
|
129
|
+
:rtype: str
|
130
|
+
"""
|
131
|
+
return self._x_obs_id_2
|
132
|
+
|
133
|
+
@x_obs_id_2.setter
|
134
|
+
def x_obs_id_2(self, x_obs_id_2):
|
135
|
+
r"""Sets the x_obs_id_2 of this PutObjectResponse.
|
136
|
+
|
137
|
+
:param x_obs_id_2: The x_obs_id_2 of this PutObjectResponse.
|
138
|
+
:type x_obs_id_2: str
|
139
|
+
"""
|
140
|
+
self._x_obs_id_2 = x_obs_id_2
|
141
|
+
|
142
|
+
@property
|
143
|
+
def x_obs_request_id(self):
|
144
|
+
r"""Gets the x_obs_request_id of this PutObjectResponse.
|
145
|
+
|
146
|
+
:return: The x_obs_request_id of this PutObjectResponse.
|
147
|
+
:rtype: str
|
148
|
+
"""
|
149
|
+
return self._x_obs_request_id
|
150
|
+
|
151
|
+
@x_obs_request_id.setter
|
152
|
+
def x_obs_request_id(self, x_obs_request_id):
|
153
|
+
r"""Sets the x_obs_request_id of this PutObjectResponse.
|
154
|
+
|
155
|
+
:param x_obs_request_id: The x_obs_request_id of this PutObjectResponse.
|
156
|
+
:type x_obs_request_id: str
|
157
|
+
"""
|
158
|
+
self._x_obs_request_id = x_obs_request_id
|
159
|
+
|
160
|
+
@property
|
161
|
+
def e_tag(self):
|
162
|
+
r"""Gets the e_tag of this PutObjectResponse.
|
163
|
+
|
164
|
+
:return: The e_tag of this PutObjectResponse.
|
165
|
+
:rtype: str
|
166
|
+
"""
|
167
|
+
return self._e_tag
|
168
|
+
|
169
|
+
@e_tag.setter
|
170
|
+
def e_tag(self, e_tag):
|
171
|
+
r"""Sets the e_tag of this PutObjectResponse.
|
172
|
+
|
173
|
+
:param e_tag: The e_tag of this PutObjectResponse.
|
174
|
+
:type e_tag: str
|
175
|
+
"""
|
176
|
+
self._e_tag = e_tag
|
177
|
+
|
178
|
+
@property
|
179
|
+
def x_obs_server_side_encryption(self):
|
180
|
+
r"""Gets the x_obs_server_side_encryption of this PutObjectResponse.
|
181
|
+
|
182
|
+
:return: The x_obs_server_side_encryption of this PutObjectResponse.
|
183
|
+
:rtype: str
|
184
|
+
"""
|
185
|
+
return self._x_obs_server_side_encryption
|
186
|
+
|
187
|
+
@x_obs_server_side_encryption.setter
|
188
|
+
def x_obs_server_side_encryption(self, x_obs_server_side_encryption):
|
189
|
+
r"""Sets the x_obs_server_side_encryption of this PutObjectResponse.
|
190
|
+
|
191
|
+
:param x_obs_server_side_encryption: The x_obs_server_side_encryption of this PutObjectResponse.
|
192
|
+
:type x_obs_server_side_encryption: str
|
193
|
+
"""
|
194
|
+
self._x_obs_server_side_encryption = x_obs_server_side_encryption
|
195
|
+
|
196
|
+
@property
|
197
|
+
def x_obs_server_side_encryption_customer_algorithm(self):
|
198
|
+
r"""Gets the x_obs_server_side_encryption_customer_algorithm of this PutObjectResponse.
|
199
|
+
|
200
|
+
:return: The x_obs_server_side_encryption_customer_algorithm of this PutObjectResponse.
|
201
|
+
:rtype: str
|
202
|
+
"""
|
203
|
+
return self._x_obs_server_side_encryption_customer_algorithm
|
204
|
+
|
205
|
+
@x_obs_server_side_encryption_customer_algorithm.setter
|
206
|
+
def x_obs_server_side_encryption_customer_algorithm(self, x_obs_server_side_encryption_customer_algorithm):
|
207
|
+
r"""Sets the x_obs_server_side_encryption_customer_algorithm of this PutObjectResponse.
|
208
|
+
|
209
|
+
:param x_obs_server_side_encryption_customer_algorithm: The x_obs_server_side_encryption_customer_algorithm of this PutObjectResponse.
|
210
|
+
:type x_obs_server_side_encryption_customer_algorithm: str
|
211
|
+
"""
|
212
|
+
self._x_obs_server_side_encryption_customer_algorithm = x_obs_server_side_encryption_customer_algorithm
|
213
|
+
|
214
|
+
@property
|
215
|
+
def x_obs_storage_class(self):
|
216
|
+
r"""Gets the x_obs_storage_class of this PutObjectResponse.
|
217
|
+
|
218
|
+
:return: The x_obs_storage_class of this PutObjectResponse.
|
219
|
+
:rtype: str
|
220
|
+
"""
|
221
|
+
return self._x_obs_storage_class
|
222
|
+
|
223
|
+
@x_obs_storage_class.setter
|
224
|
+
def x_obs_storage_class(self, x_obs_storage_class):
|
225
|
+
r"""Sets the x_obs_storage_class of this PutObjectResponse.
|
226
|
+
|
227
|
+
:param x_obs_storage_class: The x_obs_storage_class of this PutObjectResponse.
|
228
|
+
:type x_obs_storage_class: str
|
229
|
+
"""
|
230
|
+
self._x_obs_storage_class = x_obs_storage_class
|
231
|
+
|
232
|
+
@property
|
233
|
+
def connection(self):
|
234
|
+
r"""Gets the connection of this PutObjectResponse.
|
235
|
+
|
236
|
+
:return: The connection of this PutObjectResponse.
|
237
|
+
:rtype: str
|
238
|
+
"""
|
239
|
+
return self._connection
|
240
|
+
|
241
|
+
@connection.setter
|
242
|
+
def connection(self, connection):
|
243
|
+
r"""Sets the connection of this PutObjectResponse.
|
244
|
+
|
245
|
+
:param connection: The connection of this PutObjectResponse.
|
246
|
+
:type connection: str
|
247
|
+
"""
|
248
|
+
self._connection = connection
|
249
|
+
|
250
|
+
@property
|
251
|
+
def x_obs_server_side_encryption_customer_key_md5(self):
|
252
|
+
r"""Gets the x_obs_server_side_encryption_customer_key_md5 of this PutObjectResponse.
|
253
|
+
|
254
|
+
:return: The x_obs_server_side_encryption_customer_key_md5 of this PutObjectResponse.
|
255
|
+
:rtype: str
|
256
|
+
"""
|
257
|
+
return self._x_obs_server_side_encryption_customer_key_md5
|
258
|
+
|
259
|
+
@x_obs_server_side_encryption_customer_key_md5.setter
|
260
|
+
def x_obs_server_side_encryption_customer_key_md5(self, x_obs_server_side_encryption_customer_key_md5):
|
261
|
+
r"""Sets the x_obs_server_side_encryption_customer_key_md5 of this PutObjectResponse.
|
262
|
+
|
263
|
+
:param x_obs_server_side_encryption_customer_key_md5: The x_obs_server_side_encryption_customer_key_md5 of this PutObjectResponse.
|
264
|
+
:type x_obs_server_side_encryption_customer_key_md5: str
|
265
|
+
"""
|
266
|
+
self._x_obs_server_side_encryption_customer_key_md5 = x_obs_server_side_encryption_customer_key_md5
|
267
|
+
|
268
|
+
@property
|
269
|
+
def x_obs_server_side_encryption_kms_key_id(self):
|
270
|
+
r"""Gets the x_obs_server_side_encryption_kms_key_id of this PutObjectResponse.
|
271
|
+
|
272
|
+
:return: The x_obs_server_side_encryption_kms_key_id of this PutObjectResponse.
|
273
|
+
:rtype: str
|
274
|
+
"""
|
275
|
+
return self._x_obs_server_side_encryption_kms_key_id
|
276
|
+
|
277
|
+
@x_obs_server_side_encryption_kms_key_id.setter
|
278
|
+
def x_obs_server_side_encryption_kms_key_id(self, x_obs_server_side_encryption_kms_key_id):
|
279
|
+
r"""Sets the x_obs_server_side_encryption_kms_key_id of this PutObjectResponse.
|
280
|
+
|
281
|
+
:param x_obs_server_side_encryption_kms_key_id: The x_obs_server_side_encryption_kms_key_id of this PutObjectResponse.
|
282
|
+
:type x_obs_server_side_encryption_kms_key_id: str
|
283
|
+
"""
|
284
|
+
self._x_obs_server_side_encryption_kms_key_id = x_obs_server_side_encryption_kms_key_id
|
285
|
+
|
286
|
+
@property
|
287
|
+
def content_length(self):
|
288
|
+
r"""Gets the content_length of this PutObjectResponse.
|
289
|
+
|
290
|
+
:return: The content_length of this PutObjectResponse.
|
291
|
+
:rtype: str
|
292
|
+
"""
|
293
|
+
return self._content_length
|
294
|
+
|
295
|
+
@content_length.setter
|
296
|
+
def content_length(self, content_length):
|
297
|
+
r"""Sets the content_length of this PutObjectResponse.
|
298
|
+
|
299
|
+
:param content_length: The content_length of this PutObjectResponse.
|
300
|
+
:type content_length: str
|
301
|
+
"""
|
302
|
+
self._content_length = content_length
|
303
|
+
|
304
|
+
@property
|
305
|
+
def date(self):
|
306
|
+
r"""Gets the date of this PutObjectResponse.
|
307
|
+
|
308
|
+
:return: The date of this PutObjectResponse.
|
309
|
+
:rtype: str
|
310
|
+
"""
|
311
|
+
return self._date
|
312
|
+
|
313
|
+
@date.setter
|
314
|
+
def date(self, date):
|
315
|
+
r"""Sets the date of this PutObjectResponse.
|
316
|
+
|
317
|
+
:param date: The date of this PutObjectResponse.
|
318
|
+
:type date: str
|
319
|
+
"""
|
320
|
+
self._date = date
|
321
|
+
|
322
|
+
@property
|
323
|
+
def x_obs_version_id(self):
|
324
|
+
r"""Gets the x_obs_version_id of this PutObjectResponse.
|
325
|
+
|
326
|
+
:return: The x_obs_version_id of this PutObjectResponse.
|
327
|
+
:rtype: str
|
328
|
+
"""
|
329
|
+
return self._x_obs_version_id
|
330
|
+
|
331
|
+
@x_obs_version_id.setter
|
332
|
+
def x_obs_version_id(self, x_obs_version_id):
|
333
|
+
r"""Sets the x_obs_version_id of this PutObjectResponse.
|
334
|
+
|
335
|
+
:param x_obs_version_id: The x_obs_version_id of this PutObjectResponse.
|
336
|
+
:type x_obs_version_id: str
|
337
|
+
"""
|
338
|
+
self._x_obs_version_id = x_obs_version_id
|
339
|
+
|
340
|
+
def to_dict(self):
|
341
|
+
"""Returns the model properties as a dict"""
|
342
|
+
result = {}
|
343
|
+
|
344
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
345
|
+
value = getattr(self, attr)
|
346
|
+
if isinstance(value, list):
|
347
|
+
result[attr] = list(map(
|
348
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
349
|
+
value
|
350
|
+
))
|
351
|
+
elif hasattr(value, "to_dict"):
|
352
|
+
result[attr] = value.to_dict()
|
353
|
+
elif isinstance(value, dict):
|
354
|
+
result[attr] = dict(map(
|
355
|
+
lambda item: (item[0], item[1].to_dict())
|
356
|
+
if hasattr(item[1], "to_dict") else item,
|
357
|
+
value.items()
|
358
|
+
))
|
359
|
+
else:
|
360
|
+
if attr in self.sensitive_list:
|
361
|
+
result[attr] = "****"
|
362
|
+
else:
|
363
|
+
result[attr] = value
|
364
|
+
|
365
|
+
return result
|
366
|
+
|
367
|
+
def to_str(self):
|
368
|
+
"""Returns the string representation of the model"""
|
369
|
+
import simplejson as json
|
370
|
+
if six.PY2:
|
371
|
+
import sys
|
372
|
+
reload(sys)
|
373
|
+
sys.setdefaultencoding("utf-8")
|
374
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
375
|
+
|
376
|
+
def __repr__(self):
|
377
|
+
"""For `print`"""
|
378
|
+
return self.to_str()
|
379
|
+
|
380
|
+
def __eq__(self, other):
|
381
|
+
"""Returns true if both objects are equal"""
|
382
|
+
if not isinstance(other, PutObjectResponse):
|
383
|
+
return False
|
384
|
+
|
385
|
+
return self.__dict__ == other.__dict__
|
386
|
+
|
387
|
+
def __ne__(self, other):
|
388
|
+
"""Returns true if both objects are not equal"""
|
389
|
+
return not self == other
|
@@ -0,0 +1,227 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class SetBucketAclRequest:
|
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
|
+
xml_name = "SetBucketAclRequest"
|
18
|
+
|
19
|
+
sensitive_list = []
|
20
|
+
|
21
|
+
openapi_types = {
|
22
|
+
'date': 'str',
|
23
|
+
'bucket_name': 'str',
|
24
|
+
'acl': 'str',
|
25
|
+
'x_obs_acl': 'str',
|
26
|
+
'body': 'SetBucketAclRequestBody'
|
27
|
+
}
|
28
|
+
|
29
|
+
attribute_map = {
|
30
|
+
'date': 'Date',
|
31
|
+
'bucket_name': 'bucket_name',
|
32
|
+
'acl': 'acl',
|
33
|
+
'x_obs_acl': 'x-obs-acl',
|
34
|
+
'body': 'body'
|
35
|
+
}
|
36
|
+
|
37
|
+
def __init__(self, date=None, bucket_name=None, acl=None, x_obs_acl=None, body=None):
|
38
|
+
r"""SetBucketAclRequest
|
39
|
+
|
40
|
+
The model defined in huaweicloud sdk
|
41
|
+
|
42
|
+
:param date: Time when a request was initiated, for example, **Wed, 27 Jun 2018 13:39:15 +0000**. Default value: none Restriction: This header is optional if the **x-obs-date** header is contained in the request, but mandatory in other circumstances.
|
43
|
+
:type date: str
|
44
|
+
:param bucket_name: Name of the requested bucket
|
45
|
+
:type bucket_name: str
|
46
|
+
:param acl: Indicates the API for sending a request to the ACL.
|
47
|
+
:type acl: str
|
48
|
+
:param x_obs_acl: Uses a canned ACL for the bucket.Value options: **private**, **public-read**, **public-read-write**, **public-read-delivered**, or **public-read-write-delivered**
|
49
|
+
:type x_obs_acl: str
|
50
|
+
:param body: Body of the SetBucketAclRequest
|
51
|
+
:type body: :class:`huaweicloudsdkobs.v1.SetBucketAclRequestBody`
|
52
|
+
"""
|
53
|
+
|
54
|
+
|
55
|
+
|
56
|
+
self._date = None
|
57
|
+
self._bucket_name = None
|
58
|
+
self._acl = None
|
59
|
+
self._x_obs_acl = None
|
60
|
+
self._body = None
|
61
|
+
self.discriminator = None
|
62
|
+
|
63
|
+
if date is not None:
|
64
|
+
self.date = date
|
65
|
+
self.bucket_name = bucket_name
|
66
|
+
self.acl = acl
|
67
|
+
if x_obs_acl is not None:
|
68
|
+
self.x_obs_acl = x_obs_acl
|
69
|
+
if body is not None:
|
70
|
+
self.body = body
|
71
|
+
|
72
|
+
@property
|
73
|
+
def date(self):
|
74
|
+
r"""Gets the date of this SetBucketAclRequest.
|
75
|
+
|
76
|
+
Time when a request was initiated, for example, **Wed, 27 Jun 2018 13:39:15 +0000**. Default value: none Restriction: This header is optional if the **x-obs-date** header is contained in the request, but mandatory in other circumstances.
|
77
|
+
|
78
|
+
:return: The date of this SetBucketAclRequest.
|
79
|
+
:rtype: str
|
80
|
+
"""
|
81
|
+
return self._date
|
82
|
+
|
83
|
+
@date.setter
|
84
|
+
def date(self, date):
|
85
|
+
r"""Sets the date of this SetBucketAclRequest.
|
86
|
+
|
87
|
+
Time when a request was initiated, for example, **Wed, 27 Jun 2018 13:39:15 +0000**. Default value: none Restriction: This header is optional if the **x-obs-date** header is contained in the request, but mandatory in other circumstances.
|
88
|
+
|
89
|
+
:param date: The date of this SetBucketAclRequest.
|
90
|
+
:type date: str
|
91
|
+
"""
|
92
|
+
self._date = date
|
93
|
+
|
94
|
+
@property
|
95
|
+
def bucket_name(self):
|
96
|
+
r"""Gets the bucket_name of this SetBucketAclRequest.
|
97
|
+
|
98
|
+
Name of the requested bucket
|
99
|
+
|
100
|
+
:return: The bucket_name of this SetBucketAclRequest.
|
101
|
+
:rtype: str
|
102
|
+
"""
|
103
|
+
return self._bucket_name
|
104
|
+
|
105
|
+
@bucket_name.setter
|
106
|
+
def bucket_name(self, bucket_name):
|
107
|
+
r"""Sets the bucket_name of this SetBucketAclRequest.
|
108
|
+
|
109
|
+
Name of the requested bucket
|
110
|
+
|
111
|
+
:param bucket_name: The bucket_name of this SetBucketAclRequest.
|
112
|
+
:type bucket_name: str
|
113
|
+
"""
|
114
|
+
self._bucket_name = bucket_name
|
115
|
+
|
116
|
+
@property
|
117
|
+
def acl(self):
|
118
|
+
r"""Gets the acl of this SetBucketAclRequest.
|
119
|
+
|
120
|
+
Indicates the API for sending a request to the ACL.
|
121
|
+
|
122
|
+
:return: The acl of this SetBucketAclRequest.
|
123
|
+
:rtype: str
|
124
|
+
"""
|
125
|
+
return self._acl
|
126
|
+
|
127
|
+
@acl.setter
|
128
|
+
def acl(self, acl):
|
129
|
+
r"""Sets the acl of this SetBucketAclRequest.
|
130
|
+
|
131
|
+
Indicates the API for sending a request to the ACL.
|
132
|
+
|
133
|
+
:param acl: The acl of this SetBucketAclRequest.
|
134
|
+
:type acl: str
|
135
|
+
"""
|
136
|
+
self._acl = acl
|
137
|
+
|
138
|
+
@property
|
139
|
+
def x_obs_acl(self):
|
140
|
+
r"""Gets the x_obs_acl of this SetBucketAclRequest.
|
141
|
+
|
142
|
+
Uses a canned ACL for the bucket.Value options: **private**, **public-read**, **public-read-write**, **public-read-delivered**, or **public-read-write-delivered**
|
143
|
+
|
144
|
+
:return: The x_obs_acl of this SetBucketAclRequest.
|
145
|
+
:rtype: str
|
146
|
+
"""
|
147
|
+
return self._x_obs_acl
|
148
|
+
|
149
|
+
@x_obs_acl.setter
|
150
|
+
def x_obs_acl(self, x_obs_acl):
|
151
|
+
r"""Sets the x_obs_acl of this SetBucketAclRequest.
|
152
|
+
|
153
|
+
Uses a canned ACL for the bucket.Value options: **private**, **public-read**, **public-read-write**, **public-read-delivered**, or **public-read-write-delivered**
|
154
|
+
|
155
|
+
:param x_obs_acl: The x_obs_acl of this SetBucketAclRequest.
|
156
|
+
:type x_obs_acl: str
|
157
|
+
"""
|
158
|
+
self._x_obs_acl = x_obs_acl
|
159
|
+
|
160
|
+
@property
|
161
|
+
def body(self):
|
162
|
+
r"""Gets the body of this SetBucketAclRequest.
|
163
|
+
|
164
|
+
:return: The body of this SetBucketAclRequest.
|
165
|
+
:rtype: :class:`huaweicloudsdkobs.v1.SetBucketAclRequestBody`
|
166
|
+
"""
|
167
|
+
return self._body
|
168
|
+
|
169
|
+
@body.setter
|
170
|
+
def body(self, body):
|
171
|
+
r"""Sets the body of this SetBucketAclRequest.
|
172
|
+
|
173
|
+
:param body: The body of this SetBucketAclRequest.
|
174
|
+
:type body: :class:`huaweicloudsdkobs.v1.SetBucketAclRequestBody`
|
175
|
+
"""
|
176
|
+
self._body = body
|
177
|
+
|
178
|
+
def to_dict(self):
|
179
|
+
"""Returns the model properties as a dict"""
|
180
|
+
result = {}
|
181
|
+
|
182
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
183
|
+
value = getattr(self, attr)
|
184
|
+
if isinstance(value, list):
|
185
|
+
result[attr] = list(map(
|
186
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
187
|
+
value
|
188
|
+
))
|
189
|
+
elif hasattr(value, "to_dict"):
|
190
|
+
result[attr] = value.to_dict()
|
191
|
+
elif isinstance(value, dict):
|
192
|
+
result[attr] = dict(map(
|
193
|
+
lambda item: (item[0], item[1].to_dict())
|
194
|
+
if hasattr(item[1], "to_dict") else item,
|
195
|
+
value.items()
|
196
|
+
))
|
197
|
+
else:
|
198
|
+
if attr in self.sensitive_list:
|
199
|
+
result[attr] = "****"
|
200
|
+
else:
|
201
|
+
result[attr] = value
|
202
|
+
|
203
|
+
return result
|
204
|
+
|
205
|
+
def to_str(self):
|
206
|
+
"""Returns the string representation of the model"""
|
207
|
+
import simplejson as json
|
208
|
+
if six.PY2:
|
209
|
+
import sys
|
210
|
+
reload(sys)
|
211
|
+
sys.setdefaultencoding("utf-8")
|
212
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
213
|
+
|
214
|
+
def __repr__(self):
|
215
|
+
"""For `print`"""
|
216
|
+
return self.to_str()
|
217
|
+
|
218
|
+
def __eq__(self, other):
|
219
|
+
"""Returns true if both objects are equal"""
|
220
|
+
if not isinstance(other, SetBucketAclRequest):
|
221
|
+
return False
|
222
|
+
|
223
|
+
return self.__dict__ == other.__dict__
|
224
|
+
|
225
|
+
def __ne__(self, other):
|
226
|
+
"""Returns true if both objects are not equal"""
|
227
|
+
return not self == other
|