MCPcopy Create free account
hub / github.com/EasyIME/PIME / __init__

Method __init__

python/python3/tornado/tcpclient.py:55–73  ·  view source on GitHub ↗
(
        self,
        addrinfo: List[Tuple],
        connect: Callable[
            [socket.AddressFamily, Tuple], Tuple[IOStream, "Future[IOStream]"]
        ],
    )

Source from the content-addressed store, hash-verified

53 """
54
55 def __init__(
56 self,
57 addrinfo: List[Tuple],
58 connect: Callable[
59 [socket.AddressFamily, Tuple], Tuple[IOStream, "Future[IOStream]"]
60 ],
61 ) -> None:
62 self.io_loop = IOLoop.current()
63 self.connect = connect
64
65 self.future = (
66 Future()
67 ) # type: Future[Tuple[socket.AddressFamily, Any, IOStream]]
68 self.timeout = None # type: Optional[object]
69 self.connect_timeout = None # type: Optional[object]
70 self.last_error = None # type: Optional[Exception]
71 self.remaining = len(addrinfo)
72 self.primary_addrs, self.secondary_addrs = self.split(addrinfo)
73 self.streams = set() # type: Set[IOStream]
74
75 @staticmethod
76 def split(

Callers

nothing calls this directly

Calls 2

splitMethod · 0.95
currentMethod · 0.80

Tested by

no test coverage detected