huaweicloudsdkosm 3.1.164__py3-none-any.whl → 3.1.166__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 huaweicloudsdkosm might be problematic. Click here for more details.

Files changed (69) hide show
  1. huaweicloudsdkosm/v2/__init__.py +0 -60
  2. huaweicloudsdkosm/v2/model/__init__.py +0 -60
  3. huaweicloudsdkosm/v2/osm_async_client.py +45 -1130
  4. huaweicloudsdkosm/v2/osm_client.py +45 -1130
  5. {huaweicloudsdkosm-3.1.164.dist-info → huaweicloudsdkosm-3.1.166.dist-info}/METADATA +9 -10
  6. {huaweicloudsdkosm-3.1.164.dist-info → huaweicloudsdkosm-3.1.166.dist-info}/RECORD +8 -69
  7. {huaweicloudsdkosm-3.1.164.dist-info → huaweicloudsdkosm-3.1.166.dist-info}/WHEEL +1 -2
  8. huaweicloudsdkosm/v2/model/answer.py +0 -227
  9. huaweicloudsdkosm/v2/model/answer_detail.py +0 -194
  10. huaweicloudsdkosm/v2/model/answer_info.py +0 -231
  11. huaweicloudsdkosm/v2/model/answer_qa_pair.py +0 -318
  12. huaweicloudsdkosm/v2/model/article.py +0 -347
  13. huaweicloudsdkosm/v2/model/ask_question_req.py +0 -316
  14. huaweicloudsdkosm/v2/model/cbs_flow_entry.py +0 -144
  15. huaweicloudsdkosm/v2/model/create_ask_question_request.py +0 -197
  16. huaweicloudsdkosm/v2/model/create_ask_question_response.py +0 -232
  17. huaweicloudsdkosm/v2/model/create_evaluate_request.py +0 -253
  18. huaweicloudsdkosm/v2/model/create_evaluate_response.py +0 -174
  19. huaweicloudsdkosm/v2/model/create_qa_ask_request.py +0 -197
  20. huaweicloudsdkosm/v2/model/create_qa_ask_response.py +0 -282
  21. huaweicloudsdkosm/v2/model/create_qa_feedbacks_request.py +0 -226
  22. huaweicloudsdkosm/v2/model/create_qa_feedbacks_response.py +0 -174
  23. huaweicloudsdkosm/v2/model/create_question_in_session_request.py +0 -225
  24. huaweicloudsdkosm/v2/model/create_question_in_session_response.py +0 -232
  25. huaweicloudsdkosm/v2/model/create_session_request.py +0 -172
  26. huaweicloudsdkosm/v2/model/create_session_response.py +0 -174
  27. huaweicloudsdkosm/v2/model/evaluate_request_req.py +0 -115
  28. huaweicloudsdkosm/v2/model/extend_question.py +0 -144
  29. huaweicloudsdkosm/v2/model/feedback_option.py +0 -144
  30. huaweicloudsdkosm/v2/model/lang_result.py +0 -144
  31. huaweicloudsdkosm/v2/model/list_articles_request.py +0 -226
  32. huaweicloudsdkosm/v2/model/list_articles_response.py +0 -174
  33. huaweicloudsdkosm/v2/model/list_feedback_option_request.py +0 -230
  34. huaweicloudsdkosm/v2/model/list_feedback_option_response.py +0 -174
  35. huaweicloudsdkosm/v2/model/list_notices_request.py +0 -198
  36. huaweicloudsdkosm/v2/model/list_notices_response.py +0 -174
  37. huaweicloudsdkosm/v2/model/list_recommend_words_request.py +0 -260
  38. huaweicloudsdkosm/v2/model/list_recommend_words_response.py +0 -203
  39. huaweicloudsdkosm/v2/model/list_tools_request.py +0 -198
  40. huaweicloudsdkosm/v2/model/list_tools_response.py +0 -174
  41. huaweicloudsdkosm/v2/model/notice.py +0 -199
  42. huaweicloudsdkosm/v2/model/qa_ask_req.py +0 -346
  43. huaweicloudsdkosm/v2/model/qa_feedback_req.py +0 -345
  44. huaweicloudsdkosm/v2/model/qa_flow_hit_node_vo.py +0 -202
  45. huaweicloudsdkosm/v2/model/qa_flow_hit_result.py +0 -198
  46. huaweicloudsdkosm/v2/model/qa_graph_answer.py +0 -202
  47. huaweicloudsdkosm/v2/model/qa_pair.py +0 -289
  48. huaweicloudsdkosm/v2/model/qabot_answer.py +0 -347
  49. huaweicloudsdkosm/v2/model/query_associated_question_req.py +0 -172
  50. huaweicloudsdkosm/v2/model/recommend_word.py +0 -285
  51. huaweicloudsdkosm/v2/model/relation_theme.py +0 -144
  52. huaweicloudsdkosm/v2/model/relevance_qapair.py +0 -173
  53. huaweicloudsdkosm/v2/model/search_articles_req.py +0 -201
  54. huaweicloudsdkosm/v2/model/search_notices_req.py +0 -143
  55. huaweicloudsdkosm/v2/model/search_qa_pairs_req.py +0 -144
  56. huaweicloudsdkosm/v2/model/search_tools_req.py +0 -201
  57. huaweicloudsdkosm/v2/model/session_ask_question_req.py +0 -288
  58. huaweicloudsdkosm/v2/model/show_associated_questions_request.py +0 -197
  59. huaweicloudsdkosm/v2/model/show_associated_questions_response.py +0 -174
  60. huaweicloudsdkosm/v2/model/show_qa_pair_detail_request.py +0 -200
  61. huaweicloudsdkosm/v2/model/show_qa_pair_detail_response.py +0 -170
  62. huaweicloudsdkosm/v2/model/show_qa_pairs_request.py +0 -225
  63. huaweicloudsdkosm/v2/model/show_qa_pairs_response.py +0 -174
  64. huaweicloudsdkosm/v2/model/show_theme_request.py +0 -259
  65. huaweicloudsdkosm/v2/model/show_theme_response.py +0 -232
  66. huaweicloudsdkosm/v2/model/simple_qa_pair.py +0 -173
  67. huaweicloudsdkosm/v2/model/tool.py +0 -287
  68. huaweicloudsdkosm-3.1.164.dist-info/top_level.txt +0 -1
  69. {huaweicloudsdkosm-3.1.164.dist-info → huaweicloudsdkosm-3.1.166.dist-info/licenses}/LICENSE +0 -0
@@ -1,232 +0,0 @@
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 ShowThemeResponse(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
- 'themes': 'list[RelationTheme]',
22
- 'error_code': 'str',
23
- 'error_msg': 'str',
24
- 'product_type_id': 'str',
25
- 'theme_name': 'str'
26
- }
27
-
28
- attribute_map = {
29
- 'themes': 'themes',
30
- 'error_code': 'error_code',
31
- 'error_msg': 'error_msg',
32
- 'product_type_id': 'product_type_id',
33
- 'theme_name': 'theme_name'
34
- }
35
-
36
- def __init__(self, themes=None, error_code=None, error_msg=None, product_type_id=None, theme_name=None):
37
- r"""ShowThemeResponse
38
-
39
- The model defined in huaweicloud sdk
40
-
41
- :param themes: 关联主题列表
42
- :type themes: list[:class:`huaweicloudsdkosm.v2.RelationTheme`]
43
- :param error_code: 错误码
44
- :type error_code: str
45
- :param error_msg: 错误描述
46
- :type error_msg: str
47
- :param product_type_id: 产品类型Id
48
- :type product_type_id: str
49
- :param theme_name: 主题名称
50
- :type theme_name: str
51
- """
52
-
53
- super(ShowThemeResponse, self).__init__()
54
-
55
- self._themes = None
56
- self._error_code = None
57
- self._error_msg = None
58
- self._product_type_id = None
59
- self._theme_name = None
60
- self.discriminator = None
61
-
62
- if themes is not None:
63
- self.themes = themes
64
- if error_code is not None:
65
- self.error_code = error_code
66
- if error_msg is not None:
67
- self.error_msg = error_msg
68
- if product_type_id is not None:
69
- self.product_type_id = product_type_id
70
- if theme_name is not None:
71
- self.theme_name = theme_name
72
-
73
- @property
74
- def themes(self):
75
- r"""Gets the themes of this ShowThemeResponse.
76
-
77
- 关联主题列表
78
-
79
- :return: The themes of this ShowThemeResponse.
80
- :rtype: list[:class:`huaweicloudsdkosm.v2.RelationTheme`]
81
- """
82
- return self._themes
83
-
84
- @themes.setter
85
- def themes(self, themes):
86
- r"""Sets the themes of this ShowThemeResponse.
87
-
88
- 关联主题列表
89
-
90
- :param themes: The themes of this ShowThemeResponse.
91
- :type themes: list[:class:`huaweicloudsdkosm.v2.RelationTheme`]
92
- """
93
- self._themes = themes
94
-
95
- @property
96
- def error_code(self):
97
- r"""Gets the error_code of this ShowThemeResponse.
98
-
99
- 错误码
100
-
101
- :return: The error_code of this ShowThemeResponse.
102
- :rtype: str
103
- """
104
- return self._error_code
105
-
106
- @error_code.setter
107
- def error_code(self, error_code):
108
- r"""Sets the error_code of this ShowThemeResponse.
109
-
110
- 错误码
111
-
112
- :param error_code: The error_code of this ShowThemeResponse.
113
- :type error_code: str
114
- """
115
- self._error_code = error_code
116
-
117
- @property
118
- def error_msg(self):
119
- r"""Gets the error_msg of this ShowThemeResponse.
120
-
121
- 错误描述
122
-
123
- :return: The error_msg of this ShowThemeResponse.
124
- :rtype: str
125
- """
126
- return self._error_msg
127
-
128
- @error_msg.setter
129
- def error_msg(self, error_msg):
130
- r"""Sets the error_msg of this ShowThemeResponse.
131
-
132
- 错误描述
133
-
134
- :param error_msg: The error_msg of this ShowThemeResponse.
135
- :type error_msg: str
136
- """
137
- self._error_msg = error_msg
138
-
139
- @property
140
- def product_type_id(self):
141
- r"""Gets the product_type_id of this ShowThemeResponse.
142
-
143
- 产品类型Id
144
-
145
- :return: The product_type_id of this ShowThemeResponse.
146
- :rtype: str
147
- """
148
- return self._product_type_id
149
-
150
- @product_type_id.setter
151
- def product_type_id(self, product_type_id):
152
- r"""Sets the product_type_id of this ShowThemeResponse.
153
-
154
- 产品类型Id
155
-
156
- :param product_type_id: The product_type_id of this ShowThemeResponse.
157
- :type product_type_id: str
158
- """
159
- self._product_type_id = product_type_id
160
-
161
- @property
162
- def theme_name(self):
163
- r"""Gets the theme_name of this ShowThemeResponse.
164
-
165
- 主题名称
166
-
167
- :return: The theme_name of this ShowThemeResponse.
168
- :rtype: str
169
- """
170
- return self._theme_name
171
-
172
- @theme_name.setter
173
- def theme_name(self, theme_name):
174
- r"""Sets the theme_name of this ShowThemeResponse.
175
-
176
- 主题名称
177
-
178
- :param theme_name: The theme_name of this ShowThemeResponse.
179
- :type theme_name: str
180
- """
181
- self._theme_name = theme_name
182
-
183
- def to_dict(self):
184
- """Returns the model properties as a dict"""
185
- result = {}
186
-
187
- for attr, _ in six.iteritems(self.openapi_types):
188
- value = getattr(self, attr)
189
- if isinstance(value, list):
190
- result[attr] = list(map(
191
- lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
192
- value
193
- ))
194
- elif hasattr(value, "to_dict"):
195
- result[attr] = value.to_dict()
196
- elif isinstance(value, dict):
197
- result[attr] = dict(map(
198
- lambda item: (item[0], item[1].to_dict())
199
- if hasattr(item[1], "to_dict") else item,
200
- value.items()
201
- ))
202
- else:
203
- if attr in self.sensitive_list:
204
- result[attr] = "****"
205
- else:
206
- result[attr] = value
207
-
208
- return result
209
-
210
- def to_str(self):
211
- """Returns the string representation of the model"""
212
- import simplejson as json
213
- if six.PY2:
214
- import sys
215
- reload(sys)
216
- sys.setdefaultencoding("utf-8")
217
- return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
218
-
219
- def __repr__(self):
220
- """For `print`"""
221
- return self.to_str()
222
-
223
- def __eq__(self, other):
224
- """Returns true if both objects are equal"""
225
- if not isinstance(other, ShowThemeResponse):
226
- return False
227
-
228
- return self.__dict__ == other.__dict__
229
-
230
- def __ne__(self, other):
231
- """Returns true if both objects are not equal"""
232
- return not self == other
@@ -1,173 +0,0 @@
1
- # coding: utf-8
2
-
3
- import six
4
-
5
- from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
-
7
-
8
- class SimpleQaPair:
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
- 'question': 'str',
21
- 'domain': 'str',
22
- 'qa_pair_id': 'str'
23
- }
24
-
25
- attribute_map = {
26
- 'question': 'question',
27
- 'domain': 'domain',
28
- 'qa_pair_id': 'qa_pair_id'
29
- }
30
-
31
- def __init__(self, question=None, domain=None, qa_pair_id=None):
32
- r"""SimpleQaPair
33
-
34
- The model defined in huaweicloud sdk
35
-
36
- :param question: 问题
37
- :type question: str
38
- :param domain: 主题
39
- :type domain: str
40
- :param qa_pair_id: 语料Id
41
- :type qa_pair_id: str
42
- """
43
-
44
-
45
-
46
- self._question = None
47
- self._domain = None
48
- self._qa_pair_id = None
49
- self.discriminator = None
50
-
51
- if question is not None:
52
- self.question = question
53
- if domain is not None:
54
- self.domain = domain
55
- if qa_pair_id is not None:
56
- self.qa_pair_id = qa_pair_id
57
-
58
- @property
59
- def question(self):
60
- r"""Gets the question of this SimpleQaPair.
61
-
62
- 问题
63
-
64
- :return: The question of this SimpleQaPair.
65
- :rtype: str
66
- """
67
- return self._question
68
-
69
- @question.setter
70
- def question(self, question):
71
- r"""Sets the question of this SimpleQaPair.
72
-
73
- 问题
74
-
75
- :param question: The question of this SimpleQaPair.
76
- :type question: str
77
- """
78
- self._question = question
79
-
80
- @property
81
- def domain(self):
82
- r"""Gets the domain of this SimpleQaPair.
83
-
84
- 主题
85
-
86
- :return: The domain of this SimpleQaPair.
87
- :rtype: str
88
- """
89
- return self._domain
90
-
91
- @domain.setter
92
- def domain(self, domain):
93
- r"""Sets the domain of this SimpleQaPair.
94
-
95
- 主题
96
-
97
- :param domain: The domain of this SimpleQaPair.
98
- :type domain: str
99
- """
100
- self._domain = domain
101
-
102
- @property
103
- def qa_pair_id(self):
104
- r"""Gets the qa_pair_id of this SimpleQaPair.
105
-
106
- 语料Id
107
-
108
- :return: The qa_pair_id of this SimpleQaPair.
109
- :rtype: str
110
- """
111
- return self._qa_pair_id
112
-
113
- @qa_pair_id.setter
114
- def qa_pair_id(self, qa_pair_id):
115
- r"""Sets the qa_pair_id of this SimpleQaPair.
116
-
117
- 语料Id
118
-
119
- :param qa_pair_id: The qa_pair_id of this SimpleQaPair.
120
- :type qa_pair_id: str
121
- """
122
- self._qa_pair_id = qa_pair_id
123
-
124
- def to_dict(self):
125
- """Returns the model properties as a dict"""
126
- result = {}
127
-
128
- for attr, _ in six.iteritems(self.openapi_types):
129
- value = getattr(self, attr)
130
- if isinstance(value, list):
131
- result[attr] = list(map(
132
- lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
133
- value
134
- ))
135
- elif hasattr(value, "to_dict"):
136
- result[attr] = value.to_dict()
137
- elif isinstance(value, dict):
138
- result[attr] = dict(map(
139
- lambda item: (item[0], item[1].to_dict())
140
- if hasattr(item[1], "to_dict") else item,
141
- value.items()
142
- ))
143
- else:
144
- if attr in self.sensitive_list:
145
- result[attr] = "****"
146
- else:
147
- result[attr] = value
148
-
149
- return result
150
-
151
- def to_str(self):
152
- """Returns the string representation of the model"""
153
- import simplejson as json
154
- if six.PY2:
155
- import sys
156
- reload(sys)
157
- sys.setdefaultencoding("utf-8")
158
- return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
159
-
160
- def __repr__(self):
161
- """For `print`"""
162
- return self.to_str()
163
-
164
- def __eq__(self, other):
165
- """Returns true if both objects are equal"""
166
- if not isinstance(other, SimpleQaPair):
167
- return False
168
-
169
- return self.__dict__ == other.__dict__
170
-
171
- def __ne__(self, other):
172
- """Returns true if both objects are not equal"""
173
- return not self == other
@@ -1,287 +0,0 @@
1
- # coding: utf-8
2
-
3
- import six
4
-
5
- from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
-
7
-
8
- class Tool:
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
- 'name': 'str',
22
- 'url': 'str',
23
- 'icon': 'str',
24
- 'problem_type_id': 'str',
25
- 'business_type_id': 'str',
26
- 'product_type_id': 'str'
27
- }
28
-
29
- attribute_map = {
30
- 'id': 'id',
31
- 'name': 'name',
32
- 'url': 'url',
33
- 'icon': 'icon',
34
- 'problem_type_id': 'problem_type_id',
35
- 'business_type_id': 'business_type_id',
36
- 'product_type_id': 'product_type_id'
37
- }
38
-
39
- def __init__(self, id=None, name=None, url=None, icon=None, problem_type_id=None, business_type_id=None, product_type_id=None):
40
- r"""Tool
41
-
42
- The model defined in huaweicloud sdk
43
-
44
- :param id: 工具Id
45
- :type id: str
46
- :param name: 工具名称
47
- :type name: str
48
- :param url: 工具链接
49
- :type url: str
50
- :param icon: 图标内容,Base64格式
51
- :type icon: str
52
- :param problem_type_id: 问题分类Id
53
- :type problem_type_id: str
54
- :param business_type_id: 业务类型Id
55
- :type business_type_id: str
56
- :param product_type_id: 产品类型Id
57
- :type product_type_id: str
58
- """
59
-
60
-
61
-
62
- self._id = None
63
- self._name = None
64
- self._url = None
65
- self._icon = None
66
- self._problem_type_id = None
67
- self._business_type_id = None
68
- self._product_type_id = None
69
- self.discriminator = None
70
-
71
- self.id = id
72
- self.name = name
73
- if url is not None:
74
- self.url = url
75
- if icon is not None:
76
- self.icon = icon
77
- if problem_type_id is not None:
78
- self.problem_type_id = problem_type_id
79
- if business_type_id is not None:
80
- self.business_type_id = business_type_id
81
- if product_type_id is not None:
82
- self.product_type_id = product_type_id
83
-
84
- @property
85
- def id(self):
86
- r"""Gets the id of this Tool.
87
-
88
- 工具Id
89
-
90
- :return: The id of this Tool.
91
- :rtype: str
92
- """
93
- return self._id
94
-
95
- @id.setter
96
- def id(self, id):
97
- r"""Sets the id of this Tool.
98
-
99
- 工具Id
100
-
101
- :param id: The id of this Tool.
102
- :type id: str
103
- """
104
- self._id = id
105
-
106
- @property
107
- def name(self):
108
- r"""Gets the name of this Tool.
109
-
110
- 工具名称
111
-
112
- :return: The name of this Tool.
113
- :rtype: str
114
- """
115
- return self._name
116
-
117
- @name.setter
118
- def name(self, name):
119
- r"""Sets the name of this Tool.
120
-
121
- 工具名称
122
-
123
- :param name: The name of this Tool.
124
- :type name: str
125
- """
126
- self._name = name
127
-
128
- @property
129
- def url(self):
130
- r"""Gets the url of this Tool.
131
-
132
- 工具链接
133
-
134
- :return: The url of this Tool.
135
- :rtype: str
136
- """
137
- return self._url
138
-
139
- @url.setter
140
- def url(self, url):
141
- r"""Sets the url of this Tool.
142
-
143
- 工具链接
144
-
145
- :param url: The url of this Tool.
146
- :type url: str
147
- """
148
- self._url = url
149
-
150
- @property
151
- def icon(self):
152
- r"""Gets the icon of this Tool.
153
-
154
- 图标内容,Base64格式
155
-
156
- :return: The icon of this Tool.
157
- :rtype: str
158
- """
159
- return self._icon
160
-
161
- @icon.setter
162
- def icon(self, icon):
163
- r"""Sets the icon of this Tool.
164
-
165
- 图标内容,Base64格式
166
-
167
- :param icon: The icon of this Tool.
168
- :type icon: str
169
- """
170
- self._icon = icon
171
-
172
- @property
173
- def problem_type_id(self):
174
- r"""Gets the problem_type_id of this Tool.
175
-
176
- 问题分类Id
177
-
178
- :return: The problem_type_id of this Tool.
179
- :rtype: str
180
- """
181
- return self._problem_type_id
182
-
183
- @problem_type_id.setter
184
- def problem_type_id(self, problem_type_id):
185
- r"""Sets the problem_type_id of this Tool.
186
-
187
- 问题分类Id
188
-
189
- :param problem_type_id: The problem_type_id of this Tool.
190
- :type problem_type_id: str
191
- """
192
- self._problem_type_id = problem_type_id
193
-
194
- @property
195
- def business_type_id(self):
196
- r"""Gets the business_type_id of this Tool.
197
-
198
- 业务类型Id
199
-
200
- :return: The business_type_id of this Tool.
201
- :rtype: str
202
- """
203
- return self._business_type_id
204
-
205
- @business_type_id.setter
206
- def business_type_id(self, business_type_id):
207
- r"""Sets the business_type_id of this Tool.
208
-
209
- 业务类型Id
210
-
211
- :param business_type_id: The business_type_id of this Tool.
212
- :type business_type_id: str
213
- """
214
- self._business_type_id = business_type_id
215
-
216
- @property
217
- def product_type_id(self):
218
- r"""Gets the product_type_id of this Tool.
219
-
220
- 产品类型Id
221
-
222
- :return: The product_type_id of this Tool.
223
- :rtype: str
224
- """
225
- return self._product_type_id
226
-
227
- @product_type_id.setter
228
- def product_type_id(self, product_type_id):
229
- r"""Sets the product_type_id of this Tool.
230
-
231
- 产品类型Id
232
-
233
- :param product_type_id: The product_type_id of this Tool.
234
- :type product_type_id: str
235
- """
236
- self._product_type_id = product_type_id
237
-
238
- def to_dict(self):
239
- """Returns the model properties as a dict"""
240
- result = {}
241
-
242
- for attr, _ in six.iteritems(self.openapi_types):
243
- value = getattr(self, attr)
244
- if isinstance(value, list):
245
- result[attr] = list(map(
246
- lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
247
- value
248
- ))
249
- elif hasattr(value, "to_dict"):
250
- result[attr] = value.to_dict()
251
- elif isinstance(value, dict):
252
- result[attr] = dict(map(
253
- lambda item: (item[0], item[1].to_dict())
254
- if hasattr(item[1], "to_dict") else item,
255
- value.items()
256
- ))
257
- else:
258
- if attr in self.sensitive_list:
259
- result[attr] = "****"
260
- else:
261
- result[attr] = value
262
-
263
- return result
264
-
265
- def to_str(self):
266
- """Returns the string representation of the model"""
267
- import simplejson as json
268
- if six.PY2:
269
- import sys
270
- reload(sys)
271
- sys.setdefaultencoding("utf-8")
272
- return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
273
-
274
- def __repr__(self):
275
- """For `print`"""
276
- return self.to_str()
277
-
278
- def __eq__(self, other):
279
- """Returns true if both objects are equal"""
280
- if not isinstance(other, Tool):
281
- return False
282
-
283
- return self.__dict__ == other.__dict__
284
-
285
- def __ne__(self, other):
286
- """Returns true if both objects are not equal"""
287
- return not self == other
@@ -1 +0,0 @@
1
- huaweicloudsdkosm