@Override
 public void removeFinished() {
   synchronized (LOCK) {
     for (Iterator<String> theTransferIds = mySendingFiles.keySet().iterator();
         theTransferIds.hasNext(); ) {
       String theTransferId = theTransferIds.next();
       FileSender theSender = mySendingFiles.get(theTransferId);
       if (theSender.isComplete()) {
         mySendingFiles.remove(theTransferId);
         notifyTransferRemoved(theTransferId);
       }
     }
     for (Iterator<String> theTransferIds = myReceivingFiles.keySet().iterator();
         theTransferIds.hasNext(); ) {
       String theTransferId = theTransferIds.next();
       FileReceiver theReceiver = myReceivingFiles.get(theTransferId);
       if (theReceiver.isComplete()) {
         myReceivingFiles.remove(theTransferId);
         notifyTransferRemoved(theTransferId);
       }
     }
   }
 }