}
public boolean refresh() {
boolean changes = false;
for (int i = 0; i < sources.size(); i++) {
CachedConfig cachedConfig = sources.get(i).get(path);
if (cachedConfig == null) {
if (lastModifieds[i] != null) {
lastModifieds[i] = null;
changes = true;
}
} else if (lastModifieds[i] == null || cachedConfig.lastModified != lastModifieds[i]) {
lastModifieds[i] = cachedConfig.lastModified;
changes = true;
}
}
if (changes) {
List<ConfImpl> confs = new ArrayList<ConfImpl>();
for (ConfSource source : sources) {
CachedConfig cachedConfig = source.get(path);
if (cachedConfig != null) {
confs.add(cachedConfig.conf);
}
}