Package org.tmatesoft.hg.repo

Examples of org.tmatesoft.hg.repo.HgInvalidRevisionException


    final int indexSize = revisionCount();
    if (indexSize == 0 || sortedRevisions.length == 0) {
      return;
    }
    if (sortedRevisions[0] > indexSize) {
      throw new HgInvalidRevisionException(String.format("Can't iterate [%d, %d] in range [0..%d]", sortedRevisions[0], sortedRevisions[sortedRevisions.length - 1], indexSize), null, sortedRevisions[0]);
    }
    if (sortedRevisions[sortedRevisions.length - 1] > indexSize) {
      throw new HgInvalidRevisionException(String.format("Can't iterate [%d, %d] in range [0..%d]", sortedRevisions[0], sortedRevisions[sortedRevisions.length - 1], indexSize), null, sortedRevisions[sortedRevisions.length - 1]);
    }

    ReaderN1 r = new ReaderN1(needData, inspector, repo.shallMergePatches());
    try {
      r.start(sortedRevisions.length, getLastRevisionRead());
View Full Code Here


    final int last = revisionCount() - 1;
    if (revisionIndex == TIP) {
      revisionIndex = last;
    }
    if (revisionIndex < 0 || revisionIndex > last) {
      throw new HgInvalidRevisionException(revisionIndex).setRevisionIndex(revisionIndex, 0, last);
    }
    return revisionIndex;
  }
View Full Code Here

TOP

Related Classes of org.tmatesoft.hg.repo.HgInvalidRevisionException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.