Esempio n. 1
0
 @Nullable
 @Override
 public VcsRevisionNumber parseRevisionNumber(final String revisionNumberString) {
   final SVNRevision revision = SVNRevision.parse(revisionNumberString);
   if (revision.equals(SVNRevision.UNDEFINED)) {
     return null;
   }
   return new SvnRevisionNumber(revision);
 }
 private int compareRevisions(
     @NonNls final SVNRevision revision1, @NonNls final SVNRevision revision2) {
   if (revision1.equals(revision2)) {
     return 0;
   }
   // working(local) ahead of head
   if (SVNRevision.WORKING.equals(revision1)) {
     return 1;
   }
   if (SVNRevision.WORKING.equals(revision2)) {
     return -1;
   }
   if (SVNRevision.HEAD.equals(revision1)) {
     return 1;
   }
   if (SVNRevision.HEAD.equals(revision2)) {
     return -1;
   }
   return revision1.getNumber() > revision2.getNumber() ? 1 : -1;
 }