public synchronized void remove(Runnable runnable) {
    Iterator<ScheduledRunnable> iterator = runnables.iterator();
    while (iterator.hasNext()) {
      if (iterator.next().runnable == runnable) {
        iterator.remove();
      }
    }
  }
public synchronized void remove(Runnable runnable) {
    Iterator<ScheduledRunnable> iterator = runnables.iterator();
    while (iterator.hasNext()) {
      if (iterator.next().runnable == runnable) {
        iterator.remove();
      }
    }
  }
public synchronized void remove ( Runnable runnable ) { Iterator < ScheduledRunnable > iterator = runnables . iterator ( ) ; while ( iterator . hasNext ( ) ) { if ( iterator . next ( ) . runnable == runnable ) { iterator . remove ( ) ; } } }
Remove a runnable from the queue.

@param runnable  Runnable to remove.
Remove a runnable from the queue .