pulp-python-client 3.12.5__py3-none-any.whl → 3.13.0__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 pulp-python-client might be problematic. Click here for more details.
- pulp_python_client-3.13.0.dist-info/METADATA +17 -0
- pulp_python_client-3.13.0.dist-info/RECORD +64 -0
- {pulp_python_client-3.12.5.dist-info → pulp_python_client-3.13.0.dist-info}/WHEEL +1 -1
- pulpcore/client/pulp_python/__init__.py +9 -10
- pulpcore/client/pulp_python/api/__init__.py +1 -2
- pulpcore/client/pulp_python/api/content_packages_api.py +1800 -655
- pulpcore/client/pulp_python/api/distributions_pypi_api.py +3755 -1474
- pulpcore/client/pulp_python/api/publications_pypi_api.py +2574 -982
- pulpcore/client/pulp_python/api/pypi_api.py +302 -128
- pulpcore/client/pulp_python/api/pypi_legacy_api.py +326 -153
- pulpcore/client/pulp_python/api/pypi_metadata_api.py +319 -139
- pulpcore/client/pulp_python/api/pypi_simple_api.py +899 -382
- pulpcore/client/pulp_python/api/remotes_python_api.py +4092 -1589
- pulpcore/client/pulp_python/api/repositories_python_api.py +4380 -1719
- pulpcore/client/pulp_python/api/repositories_python_versions_api.py +1526 -561
- pulpcore/client/pulp_python/api_client.py +444 -313
- pulpcore/client/pulp_python/api_response.py +21 -0
- pulpcore/client/pulp_python/configuration.py +266 -73
- pulpcore/client/pulp_python/exceptions.py +99 -20
- pulpcore/client/pulp_python/models/__init__.py +5 -8
- pulpcore/client/pulp_python/models/async_operation_response.py +60 -96
- pulpcore/client/pulp_python/models/content_summary_response.py +70 -154
- pulpcore/client/pulp_python/models/exclude_platforms_enum.py +19 -82
- pulpcore/client/pulp_python/models/my_permissions_response.py +60 -94
- pulpcore/client/pulp_python/models/nested_role.py +71 -155
- pulpcore/client/pulp_python/models/nested_role_response.py +70 -152
- pulpcore/client/pulp_python/models/object_roles_response.py +70 -96
- pulpcore/client/pulp_python/models/package_metadata_response.py +91 -191
- pulpcore/client/pulp_python/models/package_types_enum.py +23 -86
- pulpcore/client/pulp_python/models/package_upload_task_response.py +85 -154
- pulpcore/client/pulp_python/models/paginated_repository_version_response_list.py +94 -181
- pulpcore/client/pulp_python/models/paginatedpython_python_distribution_response_list.py +94 -181
- pulpcore/client/pulp_python/models/paginatedpython_python_package_content_response_list.py +94 -181
- pulpcore/client/pulp_python/models/paginatedpython_python_publication_response_list.py +94 -181
- pulpcore/client/pulp_python/models/paginatedpython_python_remote_response_list.py +94 -181
- pulpcore/client/pulp_python/models/paginatedpython_python_repository_response_list.py +94 -181
- pulpcore/client/pulp_python/models/patchedpython_python_distribution.py +108 -330
- pulpcore/client/pulp_python/models/patchedpython_python_remote.py +204 -864
- pulpcore/client/pulp_python/models/patchedpython_python_repository.py +96 -249
- pulpcore/client/pulp_python/models/policy_enum.py +18 -81
- pulpcore/client/pulp_python/models/python_python_distribution.py +108 -332
- pulpcore/client/pulp_python/models/python_python_distribution_response.py +132 -490
- pulpcore/client/pulp_python/models/python_python_package_content_response.py +182 -972
- pulpcore/client/pulp_python/models/python_python_publication.py +68 -127
- pulpcore/client/pulp_python/models/python_python_publication_response.py +93 -269
- pulpcore/client/pulp_python/models/python_python_remote.py +204 -866
- pulpcore/client/pulp_python/models/python_python_remote_response.py +198 -839
- pulpcore/client/pulp_python/models/python_python_remote_response_hidden_fields_inner.py +90 -0
- pulpcore/client/pulp_python/models/python_python_repository.py +96 -250
- pulpcore/client/pulp_python/models/python_python_repository_response.py +122 -407
- pulpcore/client/pulp_python/models/repair.py +60 -95
- pulpcore/client/pulp_python/models/repository_add_remove_content.py +71 -157
- pulpcore/client/pulp_python/models/repository_sync_url.py +68 -129
- pulpcore/client/pulp_python/models/repository_version_response.py +104 -296
- pulpcore/client/pulp_python/models/set_label.py +80 -130
- pulpcore/client/pulp_python/models/set_label_response.py +80 -127
- pulpcore/client/pulp_python/models/summary_response.py +70 -160
- pulpcore/client/pulp_python/models/unset_label.py +75 -107
- pulpcore/client/pulp_python/models/unset_label_response.py +78 -129
- pulpcore/client/pulp_python/py.typed +0 -0
- pulpcore/client/pulp_python/rest.py +136 -170
- pulp_python_client-3.12.5.dist-info/METADATA +0 -17
- pulp_python_client-3.12.5.dist-info/RECORD +0 -65
- pulpcore/client/pulp_python/models/package_upload.py +0 -190
- pulpcore/client/pulp_python/models/python_bander_remote.py +0 -184
- pulpcore/client/pulp_python/models/python_python_package_content.py +0 -889
- pulpcore/client/pulp_python/models/python_python_remote_response_hidden_fields.py +0 -149
- {pulp_python_client-3.12.5.dist-info → pulp_python_client-3.13.0.dist-info}/top_level.txt +0 -0
|
@@ -3,172 +3,90 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Pulp 3 API
|
|
5
5
|
|
|
6
|
-
Fetch, Upload, Organize, and Distribute Software Packages
|
|
6
|
+
Fetch, Upload, Organize, and Distribute Software Packages
|
|
7
7
|
|
|
8
8
|
The version of the OpenAPI document: v3
|
|
9
9
|
Contact: pulp-list@redhat.com
|
|
10
|
-
Generated by
|
|
11
|
-
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
12
14
|
|
|
13
15
|
|
|
16
|
+
from __future__ import annotations
|
|
14
17
|
import pprint
|
|
15
18
|
import re # noqa: F401
|
|
19
|
+
import json
|
|
16
20
|
|
|
17
|
-
import
|
|
18
|
-
|
|
19
|
-
from
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
20
25
|
|
|
21
|
-
|
|
22
|
-
class NestedRoleResponse(object):
|
|
23
|
-
"""NOTE: This class is auto generated by OpenAPI Generator.
|
|
24
|
-
Ref: https://openapi-generator.tech
|
|
25
|
-
|
|
26
|
-
Do not edit the class manually.
|
|
26
|
+
class NestedRoleResponse(BaseModel):
|
|
27
27
|
"""
|
|
28
|
-
|
|
29
|
-
"""
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
@property
|
|
66
|
-
def users(self):
|
|
67
|
-
"""Gets the users of this NestedRoleResponse. # noqa: E501
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
:return: The users of this NestedRoleResponse. # noqa: E501
|
|
71
|
-
:rtype: list[str]
|
|
72
|
-
"""
|
|
73
|
-
return self._users
|
|
74
|
-
|
|
75
|
-
@users.setter
|
|
76
|
-
def users(self, users):
|
|
77
|
-
"""Sets the users of this NestedRoleResponse.
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
:param users: The users of this NestedRoleResponse. # noqa: E501
|
|
81
|
-
:type: list[str]
|
|
28
|
+
Serializer to add/remove object roles to/from users/groups. This is used in conjunction with ``pulpcore.app.viewsets.base.RolesMixin`` and requires the underlying object to be passed as ``content_object`` in the context.
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
users: Optional[List[StrictStr]] = None
|
|
31
|
+
groups: Optional[List[StrictStr]] = None
|
|
32
|
+
role: StrictStr
|
|
33
|
+
__properties: ClassVar[List[str]] = ["users", "groups", "role"]
|
|
34
|
+
|
|
35
|
+
model_config = ConfigDict(
|
|
36
|
+
populate_by_name=True,
|
|
37
|
+
validate_assignment=True,
|
|
38
|
+
protected_namespaces=(),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
49
|
+
return json.dumps(self.to_dict())
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
53
|
+
"""Create an instance of NestedRoleResponse from a JSON string"""
|
|
54
|
+
return cls.from_dict(json.loads(json_str))
|
|
55
|
+
|
|
56
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
57
|
+
"""Return the dictionary representation of the model using alias.
|
|
58
|
+
|
|
59
|
+
This has the following differences from calling pydantic's
|
|
60
|
+
`self.model_dump(by_alias=True)`:
|
|
61
|
+
|
|
62
|
+
* `None` is only added to the output dict for nullable fields that
|
|
63
|
+
were set at model initialization. Other fields with value `None`
|
|
64
|
+
are ignored.
|
|
82
65
|
"""
|
|
66
|
+
excluded_fields: Set[str] = set([
|
|
67
|
+
])
|
|
83
68
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
69
|
+
_dict = self.model_dump(
|
|
70
|
+
by_alias=True,
|
|
71
|
+
exclude=excluded_fields,
|
|
72
|
+
exclude_none=True,
|
|
73
|
+
)
|
|
74
|
+
return _dict
|
|
89
75
|
|
|
76
|
+
@classmethod
|
|
77
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
78
|
+
"""Create an instance of NestedRoleResponse from a dict"""
|
|
79
|
+
if obj is None:
|
|
80
|
+
return None
|
|
90
81
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
"""
|
|
94
|
-
return self._groups
|
|
95
|
-
|
|
96
|
-
@groups.setter
|
|
97
|
-
def groups(self, groups):
|
|
98
|
-
"""Sets the groups of this NestedRoleResponse.
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
:param groups: The groups of this NestedRoleResponse. # noqa: E501
|
|
102
|
-
:type: list[str]
|
|
103
|
-
"""
|
|
82
|
+
if not isinstance(obj, dict):
|
|
83
|
+
return cls.model_validate(obj)
|
|
104
84
|
|
|
105
|
-
|
|
85
|
+
_obj = cls.model_validate({
|
|
86
|
+
"users": obj.get("users"),
|
|
87
|
+
"groups": obj.get("groups"),
|
|
88
|
+
"role": obj.get("role")
|
|
89
|
+
})
|
|
90
|
+
return _obj
|
|
106
91
|
|
|
107
|
-
@property
|
|
108
|
-
def role(self):
|
|
109
|
-
"""Gets the role of this NestedRoleResponse. # noqa: E501
|
|
110
92
|
|
|
111
|
-
|
|
112
|
-
:return: The role of this NestedRoleResponse. # noqa: E501
|
|
113
|
-
:rtype: str
|
|
114
|
-
"""
|
|
115
|
-
return self._role
|
|
116
|
-
|
|
117
|
-
@role.setter
|
|
118
|
-
def role(self, role):
|
|
119
|
-
"""Sets the role of this NestedRoleResponse.
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
:param role: The role of this NestedRoleResponse. # noqa: E501
|
|
123
|
-
:type: str
|
|
124
|
-
"""
|
|
125
|
-
if self.local_vars_configuration.client_side_validation and role is None: # noqa: E501
|
|
126
|
-
raise ValueError("Invalid value for `role`, must not be `None`") # noqa: E501
|
|
127
|
-
|
|
128
|
-
self._role = role
|
|
129
|
-
|
|
130
|
-
def to_dict(self):
|
|
131
|
-
"""Returns the model properties as a dict"""
|
|
132
|
-
result = {}
|
|
133
|
-
|
|
134
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
|
135
|
-
value = getattr(self, attr)
|
|
136
|
-
if isinstance(value, list):
|
|
137
|
-
result[attr] = list(map(
|
|
138
|
-
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
|
139
|
-
value
|
|
140
|
-
))
|
|
141
|
-
elif hasattr(value, "to_dict"):
|
|
142
|
-
result[attr] = value.to_dict()
|
|
143
|
-
elif isinstance(value, dict):
|
|
144
|
-
result[attr] = dict(map(
|
|
145
|
-
lambda item: (item[0], item[1].to_dict())
|
|
146
|
-
if hasattr(item[1], "to_dict") else item,
|
|
147
|
-
value.items()
|
|
148
|
-
))
|
|
149
|
-
else:
|
|
150
|
-
result[attr] = value
|
|
151
|
-
|
|
152
|
-
return result
|
|
153
|
-
|
|
154
|
-
def to_str(self):
|
|
155
|
-
"""Returns the string representation of the model"""
|
|
156
|
-
return pprint.pformat(self.to_dict())
|
|
157
|
-
|
|
158
|
-
def __repr__(self):
|
|
159
|
-
"""For `print` and `pprint`"""
|
|
160
|
-
return self.to_str()
|
|
161
|
-
|
|
162
|
-
def __eq__(self, other):
|
|
163
|
-
"""Returns true if both objects are equal"""
|
|
164
|
-
if not isinstance(other, NestedRoleResponse):
|
|
165
|
-
return False
|
|
166
|
-
|
|
167
|
-
return self.to_dict() == other.to_dict()
|
|
168
|
-
|
|
169
|
-
def __ne__(self, other):
|
|
170
|
-
"""Returns true if both objects are not equal"""
|
|
171
|
-
if not isinstance(other, NestedRoleResponse):
|
|
172
|
-
return True
|
|
173
|
-
|
|
174
|
-
return self.to_dict() != other.to_dict()
|
|
@@ -3,120 +3,94 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Pulp 3 API
|
|
5
5
|
|
|
6
|
-
Fetch, Upload, Organize, and Distribute Software Packages
|
|
6
|
+
Fetch, Upload, Organize, and Distribute Software Packages
|
|
7
7
|
|
|
8
8
|
The version of the OpenAPI document: v3
|
|
9
9
|
Contact: pulp-list@redhat.com
|
|
10
|
-
Generated by
|
|
11
|
-
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
12
14
|
|
|
13
15
|
|
|
16
|
+
from __future__ import annotations
|
|
14
17
|
import pprint
|
|
15
18
|
import re # noqa: F401
|
|
19
|
+
import json
|
|
16
20
|
|
|
17
|
-
import
|
|
18
|
-
|
|
19
|
-
from pulpcore.client.pulp_python.
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
class ObjectRolesResponse(object):
|
|
23
|
-
"""NOTE: This class is auto generated by OpenAPI Generator.
|
|
24
|
-
Ref: https://openapi-generator.tech
|
|
21
|
+
from pydantic import BaseModel, ConfigDict
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from pulpcore.client.pulp_python.models.nested_role_response import NestedRoleResponse
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
25
26
|
|
|
26
|
-
|
|
27
|
+
class ObjectRolesResponse(BaseModel):
|
|
27
28
|
"""
|
|
29
|
+
ObjectRolesResponse
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
roles: List[NestedRoleResponse]
|
|
32
|
+
__properties: ClassVar[List[str]] = ["roles"]
|
|
28
33
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
and the value is json key in definition.
|
|
35
|
-
"""
|
|
36
|
-
openapi_types = {
|
|
37
|
-
'roles': 'list[NestedRoleResponse]'
|
|
38
|
-
}
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
populate_by_name=True,
|
|
36
|
+
validate_assignment=True,
|
|
37
|
+
protected_namespaces=(),
|
|
38
|
+
)
|
|
39
39
|
|
|
40
|
-
attribute_map = {
|
|
41
|
-
'roles': 'roles'
|
|
42
|
-
}
|
|
43
40
|
|
|
44
|
-
def
|
|
45
|
-
"""
|
|
46
|
-
|
|
47
|
-
local_vars_configuration = Configuration()
|
|
48
|
-
self.local_vars_configuration = local_vars_configuration
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
49
44
|
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
48
|
+
return json.dumps(self.to_dict())
|
|
52
49
|
|
|
53
|
-
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of ObjectRolesResponse from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
54
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
"""Gets the roles of this ObjectRolesResponse. # noqa: E501
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
58
57
|
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
59
60
|
|
|
60
|
-
|
|
61
|
-
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
62
64
|
"""
|
|
63
|
-
|
|
65
|
+
excluded_fields: Set[str] = set([
|
|
66
|
+
])
|
|
67
|
+
|
|
68
|
+
_dict = self.model_dump(
|
|
69
|
+
by_alias=True,
|
|
70
|
+
exclude=excluded_fields,
|
|
71
|
+
exclude_none=True,
|
|
72
|
+
)
|
|
73
|
+
# override the default output from pydantic by calling `to_dict()` of each item in roles (list)
|
|
74
|
+
_items = []
|
|
75
|
+
if self.roles:
|
|
76
|
+
for _item_roles in self.roles:
|
|
77
|
+
if _item_roles:
|
|
78
|
+
_items.append(_item_roles.to_dict())
|
|
79
|
+
_dict['roles'] = _items
|
|
80
|
+
return _dict
|
|
81
|
+
|
|
82
|
+
@classmethod
|
|
83
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
84
|
+
"""Create an instance of ObjectRolesResponse from a dict"""
|
|
85
|
+
if obj is None:
|
|
86
|
+
return None
|
|
87
|
+
|
|
88
|
+
if not isinstance(obj, dict):
|
|
89
|
+
return cls.model_validate(obj)
|
|
90
|
+
|
|
91
|
+
_obj = cls.model_validate({
|
|
92
|
+
"roles": [NestedRoleResponse.from_dict(_item) for _item in obj["roles"]] if obj.get("roles") is not None else None
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
64
95
|
|
|
65
|
-
@roles.setter
|
|
66
|
-
def roles(self, roles):
|
|
67
|
-
"""Sets the roles of this ObjectRolesResponse.
|
|
68
96
|
|
|
69
|
-
|
|
70
|
-
:param roles: The roles of this ObjectRolesResponse. # noqa: E501
|
|
71
|
-
:type: list[NestedRoleResponse]
|
|
72
|
-
"""
|
|
73
|
-
if self.local_vars_configuration.client_side_validation and roles is None: # noqa: E501
|
|
74
|
-
raise ValueError("Invalid value for `roles`, must not be `None`") # noqa: E501
|
|
75
|
-
|
|
76
|
-
self._roles = roles
|
|
77
|
-
|
|
78
|
-
def to_dict(self):
|
|
79
|
-
"""Returns the model properties as a dict"""
|
|
80
|
-
result = {}
|
|
81
|
-
|
|
82
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
|
83
|
-
value = getattr(self, attr)
|
|
84
|
-
if isinstance(value, list):
|
|
85
|
-
result[attr] = list(map(
|
|
86
|
-
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
|
87
|
-
value
|
|
88
|
-
))
|
|
89
|
-
elif hasattr(value, "to_dict"):
|
|
90
|
-
result[attr] = value.to_dict()
|
|
91
|
-
elif isinstance(value, dict):
|
|
92
|
-
result[attr] = dict(map(
|
|
93
|
-
lambda item: (item[0], item[1].to_dict())
|
|
94
|
-
if hasattr(item[1], "to_dict") else item,
|
|
95
|
-
value.items()
|
|
96
|
-
))
|
|
97
|
-
else:
|
|
98
|
-
result[attr] = value
|
|
99
|
-
|
|
100
|
-
return result
|
|
101
|
-
|
|
102
|
-
def to_str(self):
|
|
103
|
-
"""Returns the string representation of the model"""
|
|
104
|
-
return pprint.pformat(self.to_dict())
|
|
105
|
-
|
|
106
|
-
def __repr__(self):
|
|
107
|
-
"""For `print` and `pprint`"""
|
|
108
|
-
return self.to_str()
|
|
109
|
-
|
|
110
|
-
def __eq__(self, other):
|
|
111
|
-
"""Returns true if both objects are equal"""
|
|
112
|
-
if not isinstance(other, ObjectRolesResponse):
|
|
113
|
-
return False
|
|
114
|
-
|
|
115
|
-
return self.to_dict() == other.to_dict()
|
|
116
|
-
|
|
117
|
-
def __ne__(self, other):
|
|
118
|
-
"""Returns true if both objects are not equal"""
|
|
119
|
-
if not isinstance(other, ObjectRolesResponse):
|
|
120
|
-
return True
|
|
121
|
-
|
|
122
|
-
return self.to_dict() != other.to_dict()
|