comparison src/org/tmatesoft/hg/internal/IntSliceSeq.java @ 679:19f5167c2155

HgParentChildMap: deduce common ancestor functionality
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Sat, 20 Jul 2013 17:40:52 +0200
parents cce0387c6041
children 58a6900f845d
comparison
equal deleted inserted replaced
678:8625cba0a5a8 679:19f5167c2155
99 public void remove() { 99 public void remove() {
100 throw new UnsupportedOperationException(); 100 throw new UnsupportedOperationException();
101 } 101 }
102 }; 102 };
103 } 103 }
104
105 @Override
106 public String toString() {
107 StringBuilder sb = new StringBuilder();
108 for (int i = 0; i < size(); i++) {
109 sb.append('(');
110 for (int j = 0; j < slice; j++) {
111 sb.append(slices.get(i*slice + j));
112 sb.append(',');
113 }
114 sb.setLength(sb.length() - 1);
115 sb.append(')');
116 sb.append(' ');
117 }
118 return sb.toString();
119 }
104 120
105 private void checkArgRange(int rangeSize, int index) { 121 private void checkArgRange(int rangeSize, int index) {
106 if (index >= 0 && index < rangeSize) { 122 if (index >= 0 && index < rangeSize) {
107 return; 123 return;
108 } 124 }