We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
is_closed
1 parent 64cbd54 commit fc60126Copy full SHA for fc60126
redshift_connector/core.py
@@ -1385,6 +1385,15 @@ def close(self: "Connection") -> None:
1385
self._usock.close()
1386
self._sock = None # type: ignore
1387
1388
+ def is_closed(self: "Connection") -> bool:
1389
+ """Returns if the connection instance is closed.
1390
+
1391
+ Returns
1392
+ -------
1393
+ bool:bool
1394
+ """
1395
+ return self._sock is None
1396
1397
def handle_AUTHENTICATION_REQUEST(self: "Connection", data: bytes, cursor: Cursor) -> None:
1398
"""
1399
Handler for AuthenticationRequest message received via Amazon Redshift wire protocol, represented by
0 commit comments