comparison src/org/tmatesoft/hg/internal/IntMap.java @ 672:d2552e6a5af6

Effective update of HgParentChildMap when repository got few revisions added
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Fri, 12 Jul 2013 16:29:06 +0200
parents a937e63b6e02
children
comparison
equal deleted inserted replaced
671:002ed1b2baad 672:d2552e6a5af6
216 map.put(next.getKey(), next.getValue()); 216 map.put(next.getKey(), next.getValue());
217 } 217 }
218 return map; 218 return map;
219 } 219 }
220 220
221 public int[] keys() {
222 int[] rv = new int[size];
223 System.arraycopy(keys, 0, rv, 0, size);
224 return rv;
225 }
226
221 public Collection<V> values() { 227 public Collection<V> values() {
222 @SuppressWarnings("unchecked") 228 @SuppressWarnings("unchecked")
223 V[] rv = (V[]) new Object[size]; 229 V[] rv = (V[]) new Object[size];
224 System.arraycopy(values, 0, rv, 0, size); 230 System.arraycopy(values, 0, rv, 0, size);
225 return Arrays.<V>asList(rv); 231 return Arrays.<V>asList(rv);