public synchronized void stopAllThreads() { if (state == ExplorationProcessState.RUNNING) { state = ExplorationProcessState.STOPPING; logger.info("Stopping all threads."); for (ExplorerThread strategy : runningThreads) { strategy.stopRunning(); } } }