String fileName = SVNPathUtil.tail(myCurrentFile.myPath);
File filePath = myAdminInfo.getAnchor().getFile(myCurrentFile.myPath);
SVNAdminArea dir = myWCAccess.probeRetrieve(filePath);
SVNEntry entry = myWCAccess.getEntry(filePath, false);
SVNProperties baseProperties = null;
if (myCurrentFile.myIsAdded) {
baseProperties = new SVNProperties();
} else {
baseProperties = dir != null ? dir.getBaseProperties(fileName).asMap() : new SVNProperties();
}
SVNProperties reposProperties = applyPropChanges(baseProperties, myCurrentFile.myPropertyDiff);
String reposMimeType = reposProperties.getStringValue(SVNProperty.MIME_TYPE);
File reposFile = myCurrentFile.myFile;
File localFile = null;
if (reposFile == null) {
reposFile = dir.getBaseFile(fileName, false);
}
if (myCurrentFile.myIsAdded || (!myIsCompareToBase && entry.isScheduledForDeletion())) {
if (myIsReverseDiff) {
getDiffCallback().fileAdded(commitPath, null, reposFile, 0, myTargetRevision, null, reposMimeType, null,
myCurrentFile.myPropertyDiff, null);
} else {
getDiffCallback().fileDeleted(commitPath, reposFile, null, reposMimeType, null, reposProperties, null);
}
return;
}
boolean modified = myCurrentFile.myFile != null;
if (!modified && !myIsCompareToBase) {
modified = dir.hasTextModifications(fileName, false);
}
if (modified) {
if (myIsCompareToBase) {
localFile = dir.getBaseFile(fileName, false);
} else {
localFile = detranslateFile(dir, fileName);
}
} else {
localFile = null;
reposFile = null;
}
SVNProperties originalProps = null;
if (myIsCompareToBase) {
originalProps = baseProperties;
} else {
originalProps = dir.getProperties(fileName).asMap();
myCurrentFile.myPropertyDiff = computePropsDiff(originalProps, reposProperties);
}
if (localFile != null || (myCurrentFile.myPropertyDiff != null && !myCurrentFile.myPropertyDiff.isEmpty())) {
String originalMimeType = originalProps.getStringValue(SVNProperty.MIME_TYPE);
if (myCurrentFile.myPropertyDiff != null && !myCurrentFile.myPropertyDiff.isEmpty() && !myIsReverseDiff) {
reversePropChanges(originalProps, myCurrentFile.myPropertyDiff);
}
if (localFile != null || reposFile != null || (myCurrentFile.myPropertyDiff != null && !myCurrentFile.myPropertyDiff.isEmpty())) {
getDiffCallback().fileChanged(commitPath,