Esempio n. 1
0
    def join(self, timeout=None):
        """Ensure a Thread is stopped, drained and closed in a timely fashion.  The timeouts to respond to
        stop() and for the Thread to drain and close the socket are specified with the Constructor's
        latency= and drain= keywords; if these are reliably implemented, it is not necessary to
        provide a timeout here.

        """
        self.stop()
        ModbusConnectedRequestHandler.join(self, timeout=timeout)
Esempio n. 2
0
    def join( self, timeout=None ):
        """Ensure a Thread is stopped, drained and closed in a timely fashion.  The timeouts to respond to
        stop() and for the Thread to drain and close the socket are specified with the Constructor's
        latency= and drain= keywords; if these are reliably implemented, it is not necessary to
        provide a timeout here.

        """
        self.stop()
        ModbusConnectedRequestHandler.join( self, timeout=timeout )
Esempio n. 3
0
 def __init__(self, request, client, server):
     ModbusConnectedRequestHandler.__init__(self, request, client, server)
     if self.latency is not None:
         assert self.latency > 0, "Cannot specify a zero latency polling timeout"
Esempio n. 4
0
 def __init__( self, request, client, server ):
     ModbusConnectedRequestHandler.__init__( self, request, client, server )
     if self.latency is not None:
         assert self.latency > 0, "Cannot specify a zero latency polling timeout"