Package org.tmatesoft.hg.internal

Examples of org.tmatesoft.hg.internal.IntTuple


    }
    s1.add(21,22,23);
    errorCollector.assertEquals(2, s1.size());
    s1.add(7, 8, 9);
    s1.set(1, 4, 5, 6);
    IntTuple l = s1.last();
    errorCollector.assertEquals(7, l.at(0));
    errorCollector.assertEquals(8, l.at(1));
    errorCollector.assertEquals(9, l.at(2));
    int v = 1, slice = 0;
    for (IntTuple t : s1) {
      for (int i = 0; i < t.size(); i++) {
        errorCollector.assertEquals(String.format("Slice %d, element %d", slice, i), v++, t.at(i));
      }
View Full Code Here


           * and we try to consume p1 changes as soon as we see first p1's range
           */
          int s1TotalLines = s1To - s1From, s1ConsumedLines = 0, s1Start = s1From;
         
          for (Iterator<IntTuple> it = mergeRanges.iterator(); it.hasNext();) {
            IntTuple mergeRange = it.next();
            final int rangeOrigin = mergeRange.at(0);
            final int rangeStart = mergeRange.at(1);
            final int rangeLen = mergeRange.at(2);
            final boolean lastRange = it.hasNext();
            final int s1LinesLeft = s1TotalLines - s1ConsumedLines;
            // how many lines we may report as changed (don't use more than in range unless it's the very last range)
            final int s1LinesToBorrow = lastRange ? s1LinesLeft : Math.min(s1LinesLeft, rangeLen);
            if (s1LinesToBorrow > 0) {
View Full Code Here

TOP

Related Classes of org.tmatesoft.hg.internal.IntTuple

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.