String name = update.getName();
File current = new File(stateDir,name);
if(!current.isFile()) {
current.createNewFile();
}
ResourceFileList updateFL = ResourceFileList.load(update);
ResourceFileList currentFL = ResourceFileList.load(current);
boolean updated = false;
ResourceFileList removedFiles = currentFL.subtract(updateFL);
ResourceFileList addedFiles = updateFL.subtract(currentFL);
Iterator<ResourceFileLocation> addedItr = addedFiles.iterator();
Iterator<ResourceFileLocation> removedItr = removedFiles.iterator();
while(addedItr.hasNext()) {
updated = true;
ResourceFileLocation location = addedItr.next();
LOGGER.info("Added " + location.getName() + " " + location.getUrl());