@@ -27,32 +27,6 @@ def deactivate(self, resource_id: str, resource_data: ResourceData | None = None
2727 )
2828
2929
30- class EnablableMixin [Model ]:
31- """Enablable mixin for enabling and disabling resources."""
32-
33- def enable (self , resource_id : str , resource_data : ResourceData | None = None ) -> Model :
34- """Enable a resource.
35-
36- Args:
37- resource_id: Resource ID
38- resource_data: Resource data will be updated
39- """
40- return self ._resource_action ( # type: ignore[attr-defined, no-any-return]
41- resource_id , "POST" , "enable" , json = resource_data
42- )
43-
44- def disable (self , resource_id : str , resource_data : ResourceData | None = None ) -> Model :
45- """Disable a resource.
46-
47- Args:
48- resource_id: Resource ID
49- resource_data: Resource data will be updated
50- """
51- return self ._resource_action ( # type: ignore[attr-defined, no-any-return]
52- resource_id , "POST" , "disable" , json = resource_data
53- )
54-
55-
5630class ValidateMixin [Model ]:
5731 """Validate mixin adds the ability to validate a resource."""
5832
@@ -159,32 +133,6 @@ async def deactivate(
159133 )
160134
161135
162- class AsyncEnablableMixin [Model ]:
163- """Asynchronous Enablable mixin for enabling and disabling resources."""
164-
165- async def enable (self , resource_id : str , resource_data : ResourceData | None = None ) -> Model :
166- """Enable a resource.
167-
168- Args:
169- resource_id: Resource ID
170- resource_data: Resource data will be updated
171- """
172- return await self ._resource_action ( # type: ignore[attr-defined, no-any-return]
173- resource_id , "POST" , "enable" , json = resource_data
174- )
175-
176- async def disable (self , resource_id : str , resource_data : ResourceData | None = None ) -> Model :
177- """Disable a resource.
178-
179- Args:
180- resource_id: Resource ID
181- resource_data: Resource data will be updated
182- """
183- return await self ._resource_action ( # type: ignore[attr-defined, no-any-return]
184- resource_id , "POST" , "disable" , json = resource_data
185- )
186-
187-
188136class AsyncValidateMixin [Model ]:
189137 """Asynchronous Validate mixin adds the ability to validate a resource."""
190138
0 commit comments