Ejemplo n.º 1
0
 def get_socket_write_timeout(self):
     # type: () -> timeout
     binstr = self.socket.getsockopt(
         socket.SOL_SOCKET, socket.SO_SNDTIMEO, timeout.struct_size())
     timeo = timeout.struct_to_timeout(binstr)
     #print("Debug: get_socket_write_timeout: "
     #      "get sockopt value: %s -> returned timeout(sec=%r, microsec=%r)" %
     #      (self._hexdump(binstr), timeo.sec, timeo.microsec))
     return timeo
Ejemplo n.º 2
0
 def get_socket_write_timeout(self):
     # type: () -> SSL.timeout
     return timeout.struct_to_timeout(
         self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_SNDTIMEO,
                                timeout.struct_size()))
Ejemplo n.º 3
0
 def get_socket_read_timeout(self):
     # type: () -> timeout
     return timeout.struct_to_timeout(
         self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_RCVTIMEO,
                                timeout.struct_size()))
Ejemplo n.º 4
0
 def get_socket_write_timeout(self):
     return timeout.struct_to_timeout(
         self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_SNDTIMEO,
                                timeout.struct_size()))