11from _typeshed import Incomplete
2+ from collections .abc import Callable
3+ from logging import Logger
4+ from typing import Literal
25
3- LOGGER : Incomplete
6+ from pika import amqp_object , frame
47
5- def name_or_value (value ): ...
8+ LOGGER : Logger
9+
10+ def name_or_value (value : amqp_object .AMQPObject | frame .Frame | int | str ) -> str : ...
611def sanitize_prefix (function ): ...
712def check_for_prefix_and_key (function ): ...
813
@@ -16,16 +21,22 @@ class CallbackManager:
1621 def __init__ (self ) -> None : ...
1722 def add (
1823 self ,
19- prefix ,
20- key ,
21- callback ,
24+ prefix : str | int ,
25+ key : str | object ,
26+ callback : Callable [[ Incomplete ], Incomplete ] ,
2227 one_shot : bool = True ,
23- only_caller : Incomplete | None = None ,
28+ only_caller : object | None = None ,
2429 arguments : Incomplete | None = None ,
25- ): ...
30+ ) -> tuple [ str | int , str | object ] : ...
2631 def clear (self ) -> None : ...
27- def cleanup (self , prefix ): ...
28- def pending (self , prefix , key ): ...
29- def process (self , prefix , key , caller , * args , ** keywords ): ...
30- def remove (self , prefix , key , callback_value : Incomplete | None = None , arguments : Incomplete | None = None ): ...
31- def remove_all (self , prefix , key ) -> None : ...
32+ def cleanup (self , prefix : str | int ) -> bool : ...
33+ def pending (self , prefix : str | int , key : str | object ) -> int | None : ...
34+ def process (self , prefix : str | int , key : str | object , caller , * args , ** keywords ) -> bool : ...
35+ def remove (
36+ self ,
37+ prefix : str | int ,
38+ key : str | object ,
39+ callback_value : Callable [[Incomplete ], Incomplete ] | None = None ,
40+ arguments : Incomplete | None = None ,
41+ ) -> Literal [True ]: ...
42+ def remove_all (self , prefix : str | int , key : str | object ) -> None : ...
0 commit comments