// diffs
Filter nonConflictingFilter = getFidConflictFilter(tableName,
getActiveConflicts(tableName));
// gather all of the diff readers for the non conflicting features
VersioningFeatureSource fs = (VersioningFeatureSource) ds.getFeatureSource(tableName);
FeatureDiffReader[] readers = new FeatureDiffReader[intervals.size() - 1];
for (int i = 1; i < intervals.size(); i++) {
// mind we need to skip the actual synch points, so we subtract 1
// from the revision number
String fromVersion = String.valueOf(intervals.get(i - 1));
String toVersion = String.valueOf(intervals.get(i) - 1);
Filter filter = nonConflictingFilter;
// skip over all the clean merges
Filter cleanMerges = getFidConflictFilter(tableName, getCleanMerges(tableName,
intervals.get(i)));
if (cleanMerges != Filter.INCLUDE) {
if (filter != Filter.INCLUDE) {
filter = ff.and(cleanMerges, filter);
} else {
filter = cleanMerges;
}
}
readers[i - 1] = fs.getDifferences(fromVersion, toVersion, filter, null);
}
// now we need to merge the readers into a global set of changes, skip
// the changes on the conflicting features, and turn everything into a
// transaction (easy no?)