def on_thread_exit(self): close_directory_handle(self._directory_handle)
def on_thread_stop(self): close_directory_handle(self._directory_handle)