예제 #1
0
  /** Shuffle the observers list */
  protected void shuffleObservers() {

    logger.info("Shuffling observers list...");
    logger.debug("#Observers before shuffle = " + super.countObservers());
    logger.debug("Deleting observers...");
    super.deleteObservers();
    logger.debug("#Observers = " + super.countObservers());
    Collections.shuffle(obs, prng);
    for (Observer o : obs) {
      super.addObserver(o);
    }
    logger.debug("Observers shuffled and re-added: #Observers = " + super.countObservers());
  }
 @Override
 public void deleteObservers() {
   observable.deleteObservers();
 }
예제 #3
0
 /** Delete observers. */
 public void deleteObservers() {
   if (observable != null) {
     observable.deleteObservers();
   }
 }