minos.networks.decorators.callables.checkers module¶
- class minos.networks.decorators.callables.checkers.CheckerMeta(func, max_attempts, delay)[source]¶
Bases:
object
Checker Meta class.
- async_wrapper¶
Get the async
HandlerWrapper
instance.- Returns
A
HandlerWrapper
instance.
- delay: float¶
- func: collections.abc.Callable[minos.networks.requests.abc.Request, Union[bool, None, collections.abc.Awaitable[Optional[bool]]]]¶
- max_attempts: int¶
- async static run_async(metas, *args, **kwargs)[source]¶
Run a set of checkers asynchronously.
- Parameters
metas (
set
[minos.networks.decorators.callables.checkers.CheckerMeta
]) – The set of checkers.args – Additional positional arguments.
kwargs – Additional named arguments.
- Return type
None
- Returns
This method does not return anything.
- static run_sync(metas, *args, **kwargs)[source]¶
Run a set of checkers synchronously.
- Parameters
metas (
set
[minos.networks.decorators.callables.checkers.CheckerMeta
]) – The set of checkers.args – Additional positional arguments.
kwargs – Additional named arguments.
- Return type
bool
- Returns
This method does not return anything.
- sync_wrapper¶
Get the sync
HandlerWrapper
instance.- Returns
A
HandlerWrapper
instance.
- property wrapper: minos.networks.decorators.callables.checkers.CheckerWrapper¶
Get the
HandlerWrapper
instance.- Return type
- Returns
A
HandlerWrapper
instance.