#NEWLINE# def stop( self , wait_on_join = True , join_timeout = 5 ) : #NEWLINE# #INDENT# 'Stops the thread from running.\n\n        By default, this will also block until the thread has completed (by performing a join).\n\n        @param wait_on_join: If True, will block on a join of this thread.\n        @param join_timeout: The maximum number of seconds to block for the join.\n        ' #NEWLINE# self . _run_state . stop ( ) #NEWLINE# if self . _run_state . is_running ( ) : #NEWLINE# #INDENT# self . __queue . put ( 'ignore this' ) #NEWLINE# #UNINDENT# StoppableThread . stop ( self , wait_on_join = wait_on_join , join_timeout = join_timeout )