/** * Check if a notification is relevant at this point for the given key, and if * so, note it for later. * * @param key */ private void maybeNoteChange(String key) { if (listener == null) { return; } if (currentChanges.containsKey(key)) { Pair<Integer, Object> info = currentChanges.get(key); notifications.add(new Notification(info.getFirst().intValue(), currentLocation, key, info .getSecond())); } }
@Override public void finish() { // For good measure reset(); for (Notification notification : notifications) { notification.exe(); } }