(self, p)
Called by protocol to register itself.
Called by protocol to register itself.
Called by protocol to register itself .
def registerProtocol(self, p):
        """
        Called by protocol to register itself.
        """
        WrappingFactory.registerProtocol(self, p)

        self.requests_counter += 1
        if self.requests_counter == self.allowed_requests:
            for p in ports:
                try:
                    p.stopListening()
                except Exception:
                    pass
def registerProtocol ( self , p ) : WrappingFactory . registerProtocol ( self , p ) self . requests_counter += 1 if self . requests_counter == self . allowed_requests : for p in ports : try : p . stopListening ( ) except Exception : pass