// vtags of that other record are.
for (SchemaId vtag : allVTags) {
if ((changedVTagFields != null && changedVTagFields.contains(vtag)) || updatedFieldsByScope == null) {
// changed vtags or delete: reindex regardless of fields
AbsoluteRecordId absRecordId = new AbsoluteRecordIdImpl(table, recordId);
DependantRecordIdsIterator dependants = derefMap.findDependantsOf(absRecordId);
if (log.isDebugEnabled()) {
log.debug("changed vtag: dependants of " + recordId + ": " +
depIds(derefMap.findDependantsOf(absRecordId)));
}
while (dependants.hasNext()) {
referrersAndVTags.put(dependants.next(), vtag);
}
} else {
// vtag didn't change, but some fields did change:
Set<SchemaId> fields = new HashSet<SchemaId>();
for (Scope scope : updatedFieldsByScope.keySet()) {
fields.addAll(toSchemaIds(updatedFieldsByScope.get(scope)));
}
AbsoluteRecordId absRecordId = new AbsoluteRecordIdImpl(table, recordId);
final DependantRecordIdsIterator dependants = derefMap.findDependantsOf(absRecordId, fields, vtag);
while (dependants.hasNext()) {
referrersAndVTags.put(dependants.next(), vtag);
}
}
}
if (log.isDebugEnabled()) {