Resolves to an EncryptableSocket instance once a connection is available. * * @throws SocketException * @throws CancelledException */ public function checkout(string $uri, ConnectContext $context = null, CancellationToken $token = null) : Promise; /** * Return a previously checked-out socket to the pool so it can be reused. * * @param EncryptableSocket $socket Socket instance. * * @throws \Error If the provided resource is unknown to the pool. */ public function checkin(EncryptableSocket $socket) : void; /** * Remove the specified socket from the pool. * * @param EncryptableSocket $socket Socket instance. * * @throws \Error If the provided resource is unknown to the pool. */ public function clear(EncryptableSocket $socket) : void; }