/** * Add a key of a map location to the processor that contains a location on the map that was yet * unchecked. * * @param key the key of the location that needs to be checked */ public void reportUnchecked(final long key) { synchronized (unchecked) { if (unchecked.contains(key)) { unchecked.add(key); } unchecked.notify(); } fullCheckNeeded = true; }
/** This method starts or resumes the map processor. */ @Override public synchronized void start() { pauseLoop = false; if (running) { synchronized (unchecked) { unchecked.notify(); } } else { running = true; super.start(); } }
/** Stop this thread as soon as possible. */ public void saveShutdown() { running = false; synchronized (unchecked) { unchecked.notify(); } }