huaweicloudsdkvpcep 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.
Files changed (114) hide show
  1. huaweicloudsdkvpcep/__init__.py +0 -0
  2. huaweicloudsdkvpcep/v1/__init__.py +110 -0
  3. huaweicloudsdkvpcep/v1/model/__init__.py +107 -0
  4. huaweicloudsdkvpcep/v1/model/accept_or_reject_endpoint_request.py +139 -0
  5. huaweicloudsdkvpcep/v1/model/accept_or_reject_endpoint_request_body.py +142 -0
  6. huaweicloudsdkvpcep/v1/model/accept_or_reject_endpoint_response.py +116 -0
  7. huaweicloudsdkvpcep/v1/model/add_or_remove_service_permissions_request.py +139 -0
  8. huaweicloudsdkvpcep/v1/model/add_or_remove_service_permissions_request_body.py +171 -0
  9. huaweicloudsdkvpcep/v1/model/add_or_remove_service_permissions_response.py +145 -0
  10. huaweicloudsdkvpcep/v1/model/batch_add_endpoint_service_permissions_request.py +139 -0
  11. huaweicloudsdkvpcep/v1/model/batch_add_endpoint_service_permissions_request_body.py +143 -0
  12. huaweicloudsdkvpcep/v1/model/batch_add_endpoint_service_permissions_response.py +116 -0
  13. huaweicloudsdkvpcep/v1/model/batch_add_or_remove_resource_instance_request.py +167 -0
  14. huaweicloudsdkvpcep/v1/model/batch_add_or_remove_resource_instance_request_body.py +143 -0
  15. huaweicloudsdkvpcep/v1/model/batch_add_or_remove_resource_instance_response.py +85 -0
  16. huaweicloudsdkvpcep/v1/model/batch_remove_endpoint_service_permissions_request.py +139 -0
  17. huaweicloudsdkvpcep/v1/model/batch_remove_endpoint_service_permissions_request_body.py +114 -0
  18. huaweicloudsdkvpcep/v1/model/batch_remove_endpoint_service_permissions_response.py +116 -0
  19. huaweicloudsdkvpcep/v1/model/connection_endpoints.py +318 -0
  20. huaweicloudsdkvpcep/v1/model/connections_desc.py +142 -0
  21. huaweicloudsdkvpcep/v1/model/create_endpoint_request.py +111 -0
  22. huaweicloudsdkvpcep/v1/model/create_endpoint_request_body.py +490 -0
  23. huaweicloudsdkvpcep/v1/model/create_endpoint_response.py +841 -0
  24. huaweicloudsdkvpcep/v1/model/create_endpoint_service_request.py +111 -0
  25. huaweicloudsdkvpcep/v1/model/create_endpoint_service_request_body.py +459 -0
  26. huaweicloudsdkvpcep/v1/model/create_endpoint_service_response.py +638 -0
  27. huaweicloudsdkvpcep/v1/model/delete_endpoint_policy_request.py +114 -0
  28. huaweicloudsdkvpcep/v1/model/delete_endpoint_policy_response.py +725 -0
  29. huaweicloudsdkvpcep/v1/model/delete_endpoint_request.py +114 -0
  30. huaweicloudsdkvpcep/v1/model/delete_endpoint_response.py +85 -0
  31. huaweicloudsdkvpcep/v1/model/delete_endpoint_service_request.py +114 -0
  32. huaweicloudsdkvpcep/v1/model/delete_endpoint_service_response.py +85 -0
  33. huaweicloudsdkvpcep/v1/model/endpoint_response_body.py +811 -0
  34. huaweicloudsdkvpcep/v1/model/endpoint_service.py +289 -0
  35. huaweicloudsdkvpcep/v1/model/eps_add_permission_request.py +142 -0
  36. huaweicloudsdkvpcep/v1/model/eps_permission.py +231 -0
  37. huaweicloudsdkvpcep/v1/model/eps_remove_permission_request.py +114 -0
  38. huaweicloudsdkvpcep/v1/model/eps_update_permission_desc.py +114 -0
  39. huaweicloudsdkvpcep/v1/model/error.py +144 -0
  40. huaweicloudsdkvpcep/v1/model/link.py +173 -0
  41. huaweicloudsdkvpcep/v1/model/list_endpoint_info_details_request.py +114 -0
  42. huaweicloudsdkvpcep/v1/model/list_endpoint_info_details_response.py +895 -0
  43. huaweicloudsdkvpcep/v1/model/list_endpoint_service_request.py +347 -0
  44. huaweicloudsdkvpcep/v1/model/list_endpoint_service_response.py +145 -0
  45. huaweicloudsdkvpcep/v1/model/list_endpoints_request.py +289 -0
  46. huaweicloudsdkvpcep/v1/model/list_endpoints_response.py +145 -0
  47. huaweicloudsdkvpcep/v1/model/list_query_project_resource_tags_request.py +114 -0
  48. huaweicloudsdkvpcep/v1/model/list_query_project_resource_tags_response.py +116 -0
  49. huaweicloudsdkvpcep/v1/model/list_quota_details_request.py +115 -0
  50. huaweicloudsdkvpcep/v1/model/list_quota_details_response.py +112 -0
  51. huaweicloudsdkvpcep/v1/model/list_resource_instances_request.py +139 -0
  52. huaweicloudsdkvpcep/v1/model/list_resource_instances_response.py +145 -0
  53. huaweicloudsdkvpcep/v1/model/list_service_connections_request.py +317 -0
  54. huaweicloudsdkvpcep/v1/model/list_service_connections_response.py +145 -0
  55. huaweicloudsdkvpcep/v1/model/list_service_describe_details_request.py +144 -0
  56. huaweicloudsdkvpcep/v1/model/list_service_describe_details_response.py +290 -0
  57. huaweicloudsdkvpcep/v1/model/list_service_details_request.py +114 -0
  58. huaweicloudsdkvpcep/v1/model/list_service_details_response.py +667 -0
  59. huaweicloudsdkvpcep/v1/model/list_service_permissions_details_request.py +259 -0
  60. huaweicloudsdkvpcep/v1/model/list_service_permissions_details_response.py +145 -0
  61. huaweicloudsdkvpcep/v1/model/list_service_public_details_request.py +260 -0
  62. huaweicloudsdkvpcep/v1/model/list_service_public_details_response.py +145 -0
  63. huaweicloudsdkvpcep/v1/model/list_specified_version_details_request.py +114 -0
  64. huaweicloudsdkvpcep/v1/model/list_specified_version_details_response.py +112 -0
  65. huaweicloudsdkvpcep/v1/model/list_version_details_request.py +84 -0
  66. huaweicloudsdkvpcep/v1/model/list_version_details_response.py +116 -0
  67. huaweicloudsdkvpcep/v1/model/match.py +142 -0
  68. huaweicloudsdkvpcep/v1/model/permission_object.py +202 -0
  69. huaweicloudsdkvpcep/v1/model/policy_statement.py +199 -0
  70. huaweicloudsdkvpcep/v1/model/port_list.py +173 -0
  71. huaweicloudsdkvpcep/v1/model/query_error.py +144 -0
  72. huaweicloudsdkvpcep/v1/model/query_resource_instance_tags_body.py +375 -0
  73. huaweicloudsdkvpcep/v1/model/quotas.py +173 -0
  74. huaweicloudsdkvpcep/v1/model/resource_instance.py +173 -0
  75. huaweicloudsdkvpcep/v1/model/resource_tag.py +143 -0
  76. huaweicloudsdkvpcep/v1/model/resources_response_body.py +115 -0
  77. huaweicloudsdkvpcep/v1/model/routetable_info_error.py +144 -0
  78. huaweicloudsdkvpcep/v1/model/routetable_info_error_detial.py +144 -0
  79. huaweicloudsdkvpcep/v1/model/service_list.py +724 -0
  80. huaweicloudsdkvpcep/v1/model/tag_list.py +144 -0
  81. huaweicloudsdkvpcep/v1/model/tag_values_list.py +142 -0
  82. huaweicloudsdkvpcep/v1/model/update_endpoint_connections_desc_request.py +139 -0
  83. huaweicloudsdkvpcep/v1/model/update_endpoint_connections_desc_request_body.py +114 -0
  84. huaweicloudsdkvpcep/v1/model/update_endpoint_connections_desc_response.py +116 -0
  85. huaweicloudsdkvpcep/v1/model/update_endpoint_policy_request.py +139 -0
  86. huaweicloudsdkvpcep/v1/model/update_endpoint_policy_request_body.py +144 -0
  87. huaweicloudsdkvpcep/v1/model/update_endpoint_policy_response.py +725 -0
  88. huaweicloudsdkvpcep/v1/model/update_endpoint_routetable_request.py +139 -0
  89. huaweicloudsdkvpcep/v1/model/update_endpoint_routetable_request_body.py +114 -0
  90. huaweicloudsdkvpcep/v1/model/update_endpoint_routetable_response.py +145 -0
  91. huaweicloudsdkvpcep/v1/model/update_endpoint_service_name_request.py +139 -0
  92. huaweicloudsdkvpcep/v1/model/update_endpoint_service_name_request_body.py +115 -0
  93. huaweicloudsdkvpcep/v1/model/update_endpoint_service_name_response.py +116 -0
  94. huaweicloudsdkvpcep/v1/model/update_endpoint_service_permission_desc_request.py +167 -0
  95. huaweicloudsdkvpcep/v1/model/update_endpoint_service_permission_desc_request_body.py +110 -0
  96. huaweicloudsdkvpcep/v1/model/update_endpoint_service_permission_desc_response.py +116 -0
  97. huaweicloudsdkvpcep/v1/model/update_endpoint_service_request.py +139 -0
  98. huaweicloudsdkvpcep/v1/model/update_endpoint_service_request_body.py +289 -0
  99. huaweicloudsdkvpcep/v1/model/update_endpoint_service_response.py +638 -0
  100. huaweicloudsdkvpcep/v1/model/update_endpoint_white_request.py +139 -0
  101. huaweicloudsdkvpcep/v1/model/update_endpoint_white_request_body.py +144 -0
  102. huaweicloudsdkvpcep/v1/model/update_endpoint_white_response.py +667 -0
  103. huaweicloudsdkvpcep/v1/model/upgrade_endpoint_service_request.py +114 -0
  104. huaweicloudsdkvpcep/v1/model/upgrade_endpoint_service_response.py +85 -0
  105. huaweicloudsdkvpcep/v1/model/version_object.py +260 -0
  106. huaweicloudsdkvpcep/v1/region/__init__.py +0 -0
  107. huaweicloudsdkvpcep/v1/region/vpcep_region.py +124 -0
  108. huaweicloudsdkvpcep/v1/vpcep_async_client.py +2211 -0
  109. huaweicloudsdkvpcep/v1/vpcep_client.py +2208 -0
  110. huaweicloudsdkvpcep-3.1.160.dist-info/LICENSE +13 -0
  111. huaweicloudsdkvpcep-3.1.160.dist-info/METADATA +26 -0
  112. huaweicloudsdkvpcep-3.1.160.dist-info/RECORD +114 -0
  113. huaweicloudsdkvpcep-3.1.160.dist-info/WHEEL +5 -0
  114. huaweicloudsdkvpcep-3.1.160.dist-info/top_level.txt +1 -0
@@ -0,0 +1,142 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class Match:
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
+ 'key': 'str',
21
+ 'value': 'str'
22
+ }
23
+
24
+ attribute_map = {
25
+ 'key': 'key',
26
+ 'value': 'value'
27
+ }
28
+
29
+ def __init__(self, key=None, value=None):
30
+ r"""Match
31
+
32
+ The model defined in huaweicloud sdk
33
+
34
+ :param key: 键。第一期限定为resource_name,后续扩展。
35
+ :type key: str
36
+ :param value: 值。每个值最大长度255个unicode字符。不校验字符集范。
37
+ :type value: str
38
+ """
39
+
40
+
41
+
42
+ self._key = None
43
+ self._value = None
44
+ self.discriminator = None
45
+
46
+ self.key = key
47
+ self.value = value
48
+
49
+ @property
50
+ def key(self):
51
+ r"""Gets the key of this Match.
52
+
53
+ 键。第一期限定为resource_name,后续扩展。
54
+
55
+ :return: The key of this Match.
56
+ :rtype: str
57
+ """
58
+ return self._key
59
+
60
+ @key.setter
61
+ def key(self, key):
62
+ r"""Sets the key of this Match.
63
+
64
+ 键。第一期限定为resource_name,后续扩展。
65
+
66
+ :param key: The key of this Match.
67
+ :type key: str
68
+ """
69
+ self._key = key
70
+
71
+ @property
72
+ def value(self):
73
+ r"""Gets the value of this Match.
74
+
75
+ 值。每个值最大长度255个unicode字符。不校验字符集范。
76
+
77
+ :return: The value of this Match.
78
+ :rtype: str
79
+ """
80
+ return self._value
81
+
82
+ @value.setter
83
+ def value(self, value):
84
+ r"""Sets the value of this Match.
85
+
86
+ 值。每个值最大长度255个unicode字符。不校验字符集范。
87
+
88
+ :param value: The value of this Match.
89
+ :type value: str
90
+ """
91
+ self._value = value
92
+
93
+ def to_dict(self):
94
+ """Returns the model properties as a dict"""
95
+ result = {}
96
+
97
+ for attr, _ in six.iteritems(self.openapi_types):
98
+ value = getattr(self, attr)
99
+ if isinstance(value, list):
100
+ result[attr] = list(map(
101
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
102
+ value
103
+ ))
104
+ elif hasattr(value, "to_dict"):
105
+ result[attr] = value.to_dict()
106
+ elif isinstance(value, dict):
107
+ result[attr] = dict(map(
108
+ lambda item: (item[0], item[1].to_dict())
109
+ if hasattr(item[1], "to_dict") else item,
110
+ value.items()
111
+ ))
112
+ else:
113
+ if attr in self.sensitive_list:
114
+ result[attr] = "****"
115
+ else:
116
+ result[attr] = value
117
+
118
+ return result
119
+
120
+ def to_str(self):
121
+ """Returns the string representation of the model"""
122
+ import simplejson as json
123
+ if six.PY2:
124
+ import sys
125
+ reload(sys)
126
+ sys.setdefaultencoding("utf-8")
127
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
128
+
129
+ def __repr__(self):
130
+ """For `print`"""
131
+ return self.to_str()
132
+
133
+ def __eq__(self, other):
134
+ """Returns true if both objects are equal"""
135
+ if not isinstance(other, Match):
136
+ return False
137
+
138
+ return self.__dict__ == other.__dict__
139
+
140
+ def __ne__(self, other):
141
+ """Returns true if both objects are not equal"""
142
+ return not self == other
@@ -0,0 +1,202 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class PermissionObject:
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
+ 'permission': 'str',
22
+ 'permission_type': 'str',
23
+ 'created_at': 'datetime'
24
+ }
25
+
26
+ attribute_map = {
27
+ 'id': 'id',
28
+ 'permission': 'permission',
29
+ 'permission_type': 'permission_type',
30
+ 'created_at': 'created_at'
31
+ }
32
+
33
+ def __init__(self, id=None, permission=None, permission_type=None, created_at=None):
34
+ r"""PermissionObject
35
+
36
+ The model defined in huaweicloud sdk
37
+
38
+ :param id: permission的ID,唯一标识。
39
+ :type id: str
40
+ :param permission: permission列表。 权限格式为: - iam:domain::domain_id。其中: “iam:domain::”为固定格式,“domain_id”为可连接用户的账号ID。 domain_id类型支持输入包括“a~z”、“A~Z”、“0~9”或者“*”,最大长度可以传64。 - organizations:orgPath::org_path。其中: “organizations:orgPath::”为固定格式,org_path为可连接用户的组织路径。 org_path类型支持“a~z”、“A~Z”、“0~9”、“/-*?”或者“*”,最大长度可以传1024。 “*”表示所有终端节点可连接。 示例: - iam:domain::6e9dfd51d1124e8d8498dce894923a0dd - organizations:orgPath::o-3j59d1231uprgk9yuvlidra7zbzfi578/r-rldbu1vmxdw5ahdkknxnvd5rgag77m2z/ou-7tuddd8nh99rebxltawsm6qct5z7rklv/*
41
+ :type permission: str
42
+ :param permission_type: 终端节点服务白名单类型。 - domainId:基于账户ID配置终端节点服务白名单。 - orgPath:基于账户所在组织路径配置终端节点服务白名单。
43
+ :type permission_type: str
44
+ :param created_at: 白名单的添加时间。 采用UTC时间格式,格式为:YYYY-MM-DDTHH:MM:SSZ
45
+ :type created_at: datetime
46
+ """
47
+
48
+
49
+
50
+ self._id = None
51
+ self._permission = None
52
+ self._permission_type = None
53
+ self._created_at = None
54
+ self.discriminator = None
55
+
56
+ if id is not None:
57
+ self.id = id
58
+ if permission is not None:
59
+ self.permission = permission
60
+ if permission_type is not None:
61
+ self.permission_type = permission_type
62
+ if created_at is not None:
63
+ self.created_at = created_at
64
+
65
+ @property
66
+ def id(self):
67
+ r"""Gets the id of this PermissionObject.
68
+
69
+ permission的ID,唯一标识。
70
+
71
+ :return: The id of this PermissionObject.
72
+ :rtype: str
73
+ """
74
+ return self._id
75
+
76
+ @id.setter
77
+ def id(self, id):
78
+ r"""Sets the id of this PermissionObject.
79
+
80
+ permission的ID,唯一标识。
81
+
82
+ :param id: The id of this PermissionObject.
83
+ :type id: str
84
+ """
85
+ self._id = id
86
+
87
+ @property
88
+ def permission(self):
89
+ r"""Gets the permission of this PermissionObject.
90
+
91
+ permission列表。 权限格式为: - iam:domain::domain_id。其中: “iam:domain::”为固定格式,“domain_id”为可连接用户的账号ID。 domain_id类型支持输入包括“a~z”、“A~Z”、“0~9”或者“*”,最大长度可以传64。 - organizations:orgPath::org_path。其中: “organizations:orgPath::”为固定格式,org_path为可连接用户的组织路径。 org_path类型支持“a~z”、“A~Z”、“0~9”、“/-*?”或者“*”,最大长度可以传1024。 “*”表示所有终端节点可连接。 示例: - iam:domain::6e9dfd51d1124e8d8498dce894923a0dd - organizations:orgPath::o-3j59d1231uprgk9yuvlidra7zbzfi578/r-rldbu1vmxdw5ahdkknxnvd5rgag77m2z/ou-7tuddd8nh99rebxltawsm6qct5z7rklv/*
92
+
93
+ :return: The permission of this PermissionObject.
94
+ :rtype: str
95
+ """
96
+ return self._permission
97
+
98
+ @permission.setter
99
+ def permission(self, permission):
100
+ r"""Sets the permission of this PermissionObject.
101
+
102
+ permission列表。 权限格式为: - iam:domain::domain_id。其中: “iam:domain::”为固定格式,“domain_id”为可连接用户的账号ID。 domain_id类型支持输入包括“a~z”、“A~Z”、“0~9”或者“*”,最大长度可以传64。 - organizations:orgPath::org_path。其中: “organizations:orgPath::”为固定格式,org_path为可连接用户的组织路径。 org_path类型支持“a~z”、“A~Z”、“0~9”、“/-*?”或者“*”,最大长度可以传1024。 “*”表示所有终端节点可连接。 示例: - iam:domain::6e9dfd51d1124e8d8498dce894923a0dd - organizations:orgPath::o-3j59d1231uprgk9yuvlidra7zbzfi578/r-rldbu1vmxdw5ahdkknxnvd5rgag77m2z/ou-7tuddd8nh99rebxltawsm6qct5z7rklv/*
103
+
104
+ :param permission: The permission of this PermissionObject.
105
+ :type permission: str
106
+ """
107
+ self._permission = permission
108
+
109
+ @property
110
+ def permission_type(self):
111
+ r"""Gets the permission_type of this PermissionObject.
112
+
113
+ 终端节点服务白名单类型。 - domainId:基于账户ID配置终端节点服务白名单。 - orgPath:基于账户所在组织路径配置终端节点服务白名单。
114
+
115
+ :return: The permission_type of this PermissionObject.
116
+ :rtype: str
117
+ """
118
+ return self._permission_type
119
+
120
+ @permission_type.setter
121
+ def permission_type(self, permission_type):
122
+ r"""Sets the permission_type of this PermissionObject.
123
+
124
+ 终端节点服务白名单类型。 - domainId:基于账户ID配置终端节点服务白名单。 - orgPath:基于账户所在组织路径配置终端节点服务白名单。
125
+
126
+ :param permission_type: The permission_type of this PermissionObject.
127
+ :type permission_type: str
128
+ """
129
+ self._permission_type = permission_type
130
+
131
+ @property
132
+ def created_at(self):
133
+ r"""Gets the created_at of this PermissionObject.
134
+
135
+ 白名单的添加时间。 采用UTC时间格式,格式为:YYYY-MM-DDTHH:MM:SSZ
136
+
137
+ :return: The created_at of this PermissionObject.
138
+ :rtype: datetime
139
+ """
140
+ return self._created_at
141
+
142
+ @created_at.setter
143
+ def created_at(self, created_at):
144
+ r"""Sets the created_at of this PermissionObject.
145
+
146
+ 白名单的添加时间。 采用UTC时间格式,格式为:YYYY-MM-DDTHH:MM:SSZ
147
+
148
+ :param created_at: The created_at of this PermissionObject.
149
+ :type created_at: datetime
150
+ """
151
+ self._created_at = created_at
152
+
153
+ def to_dict(self):
154
+ """Returns the model properties as a dict"""
155
+ result = {}
156
+
157
+ for attr, _ in six.iteritems(self.openapi_types):
158
+ value = getattr(self, attr)
159
+ if isinstance(value, list):
160
+ result[attr] = list(map(
161
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
162
+ value
163
+ ))
164
+ elif hasattr(value, "to_dict"):
165
+ result[attr] = value.to_dict()
166
+ elif isinstance(value, dict):
167
+ result[attr] = dict(map(
168
+ lambda item: (item[0], item[1].to_dict())
169
+ if hasattr(item[1], "to_dict") else item,
170
+ value.items()
171
+ ))
172
+ else:
173
+ if attr in self.sensitive_list:
174
+ result[attr] = "****"
175
+ else:
176
+ result[attr] = value
177
+
178
+ return result
179
+
180
+ def to_str(self):
181
+ """Returns the string representation of the model"""
182
+ import simplejson as json
183
+ if six.PY2:
184
+ import sys
185
+ reload(sys)
186
+ sys.setdefaultencoding("utf-8")
187
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
188
+
189
+ def __repr__(self):
190
+ """For `print`"""
191
+ return self.to_str()
192
+
193
+ def __eq__(self, other):
194
+ """Returns true if both objects are equal"""
195
+ if not isinstance(other, PermissionObject):
196
+ return False
197
+
198
+ return self.__dict__ == other.__dict__
199
+
200
+ def __ne__(self, other):
201
+ """Returns true if both objects are not equal"""
202
+ return not self == other
@@ -0,0 +1,199 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class PolicyStatement:
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
+ 'effect': 'str',
21
+ 'action': 'list[str]',
22
+ 'resource': 'list[str]',
23
+ 'condition': 'object'
24
+ }
25
+
26
+ attribute_map = {
27
+ 'effect': 'Effect',
28
+ 'action': 'Action',
29
+ 'resource': 'Resource',
30
+ 'condition': 'Condition'
31
+ }
32
+
33
+ def __init__(self, effect=None, action=None, resource=None, condition=None):
34
+ r"""PolicyStatement
35
+
36
+ The model defined in huaweicloud sdk
37
+
38
+ :param effect: - Allow,允许控制访问权限 - Deny,拒绝控制访问权限
39
+ :type effect: str
40
+ :param action: obs访问权限
41
+ :type action: list[str]
42
+ :param resource: obs对象
43
+ :type resource: list[str]
44
+ :param condition: statement生效的条件
45
+ :type condition: object
46
+ """
47
+
48
+
49
+
50
+ self._effect = None
51
+ self._action = None
52
+ self._resource = None
53
+ self._condition = None
54
+ self.discriminator = None
55
+
56
+ self.effect = effect
57
+ self.action = action
58
+ self.resource = resource
59
+ if condition is not None:
60
+ self.condition = condition
61
+
62
+ @property
63
+ def effect(self):
64
+ r"""Gets the effect of this PolicyStatement.
65
+
66
+ - Allow,允许控制访问权限 - Deny,拒绝控制访问权限
67
+
68
+ :return: The effect of this PolicyStatement.
69
+ :rtype: str
70
+ """
71
+ return self._effect
72
+
73
+ @effect.setter
74
+ def effect(self, effect):
75
+ r"""Sets the effect of this PolicyStatement.
76
+
77
+ - Allow,允许控制访问权限 - Deny,拒绝控制访问权限
78
+
79
+ :param effect: The effect of this PolicyStatement.
80
+ :type effect: str
81
+ """
82
+ self._effect = effect
83
+
84
+ @property
85
+ def action(self):
86
+ r"""Gets the action of this PolicyStatement.
87
+
88
+ obs访问权限
89
+
90
+ :return: The action of this PolicyStatement.
91
+ :rtype: list[str]
92
+ """
93
+ return self._action
94
+
95
+ @action.setter
96
+ def action(self, action):
97
+ r"""Sets the action of this PolicyStatement.
98
+
99
+ obs访问权限
100
+
101
+ :param action: The action of this PolicyStatement.
102
+ :type action: list[str]
103
+ """
104
+ self._action = action
105
+
106
+ @property
107
+ def resource(self):
108
+ r"""Gets the resource of this PolicyStatement.
109
+
110
+ obs对象
111
+
112
+ :return: The resource of this PolicyStatement.
113
+ :rtype: list[str]
114
+ """
115
+ return self._resource
116
+
117
+ @resource.setter
118
+ def resource(self, resource):
119
+ r"""Sets the resource of this PolicyStatement.
120
+
121
+ obs对象
122
+
123
+ :param resource: The resource of this PolicyStatement.
124
+ :type resource: list[str]
125
+ """
126
+ self._resource = resource
127
+
128
+ @property
129
+ def condition(self):
130
+ r"""Gets the condition of this PolicyStatement.
131
+
132
+ statement生效的条件
133
+
134
+ :return: The condition of this PolicyStatement.
135
+ :rtype: object
136
+ """
137
+ return self._condition
138
+
139
+ @condition.setter
140
+ def condition(self, condition):
141
+ r"""Sets the condition of this PolicyStatement.
142
+
143
+ statement生效的条件
144
+
145
+ :param condition: The condition of this PolicyStatement.
146
+ :type condition: object
147
+ """
148
+ self._condition = condition
149
+
150
+ def to_dict(self):
151
+ """Returns the model properties as a dict"""
152
+ result = {}
153
+
154
+ for attr, _ in six.iteritems(self.openapi_types):
155
+ value = getattr(self, attr)
156
+ if isinstance(value, list):
157
+ result[attr] = list(map(
158
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
159
+ value
160
+ ))
161
+ elif hasattr(value, "to_dict"):
162
+ result[attr] = value.to_dict()
163
+ elif isinstance(value, dict):
164
+ result[attr] = dict(map(
165
+ lambda item: (item[0], item[1].to_dict())
166
+ if hasattr(item[1], "to_dict") else item,
167
+ value.items()
168
+ ))
169
+ else:
170
+ if attr in self.sensitive_list:
171
+ result[attr] = "****"
172
+ else:
173
+ result[attr] = value
174
+
175
+ return result
176
+
177
+ def to_str(self):
178
+ """Returns the string representation of the model"""
179
+ import simplejson as json
180
+ if six.PY2:
181
+ import sys
182
+ reload(sys)
183
+ sys.setdefaultencoding("utf-8")
184
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
185
+
186
+ def __repr__(self):
187
+ """For `print`"""
188
+ return self.to_str()
189
+
190
+ def __eq__(self, other):
191
+ """Returns true if both objects are equal"""
192
+ if not isinstance(other, PolicyStatement):
193
+ return False
194
+
195
+ return self.__dict__ == other.__dict__
196
+
197
+ def __ne__(self, other):
198
+ """Returns true if both objects are not equal"""
199
+ return not self == other