def stop(self, timeout=1.0):
        """Stop a running server (from another thread).

        Parameters
        ----------
        timeout : float, optional
            Seconds to wait for server to have *started*.

        Returns
        -------
        stopped : thread-safe Future
            Resolves when the server is stopped

        """
        stopped = self._server.stop(timeout)
        if self._handler_thread:
            self._handler_thread.stop(timeout)

        return stopped
def stop ( self , timeout = 1.0 ) : stopped = self . _server . stop ( timeout ) if self . _handler_thread : self . _handler_thread . stop ( timeout ) return stopped
Stop a running server (from another thread).

        Parameters
        ----------
        timeout : float, optional
            Seconds to wait for server to have *started*.

        Returns
        -------
        stopped : thread-safe Future
            Resolves when the server is stopped