コード例 #1
0
 protected SvnFileRevision createRevision(
     final LogEntry logEntry, final String copyPath, LogEntryPath entryPath)
     throws SVNException {
   Date date = logEntry.getDate();
   String author = logEntry.getAuthor();
   String message = logEntry.getMessage();
   SVNRevision rev = SVNRevision.create(logEntry.getRevision());
   final SVNURL url = myRepositoryRoot.appendPath(myLastPath, true);
   //      final SVNURL url = entryPath != null ?
   // myRepositoryRoot.appendPath(entryPath.getPath(), true) :
   //                         myRepositoryRoot.appendPath(myLastPathCorrector.getBefore(),
   // false);
   return new SvnFileRevision(
       myVcs, myPegRevision, rev, url.toString(), author, date, message, copyPath, myCharset);
 }
コード例 #2
0
 // TODO: this makes sense only for directories, but should always return true if something under
 // the directory was changed in revision
 // TODO: as svn will provide child changes in history for directory
 private boolean checkForChildChanges(LogEntry logEntry) {
   final String lastPathBefore = myLastPathCorrector.getBefore();
   for (String key : logEntry.getChangedPaths().keySet()) {
     if (SVNPathUtil.isAncestor(lastPathBefore, key)) {
       return true;
     }
   }
   return false;
 }
コード例 #3
0
 private boolean checkForParentChanges(LogEntry logEntry) {
   final String lastPathBefore = myLastPathCorrector.getBefore();
   String path = SVNPathUtil.removeTail(lastPathBefore);
   while (path.length() > 0) {
     final LogEntryPath entryPath = logEntry.getChangedPaths().get(path);
     // A & D are checked since we are not interested in parent folders property changes, only in
     // structure changes
     // TODO: seems that R (replaced) should also be checked here
     if (entryPath != null && (entryPath.getType() == 'A' || entryPath.getType() == 'D')) {
       if (entryPath.getCopyPath() != null) {
         return true;
       }
       break;
     }
     path = SVNPathUtil.removeTail(path);
   }
   return false;
 }