/** Create a map from Integers -5 to -1 to Strings "A"-"E". */ private static ConcurrentNavigableMap dmap5() { ConcurrentSkipListMap map = new ConcurrentSkipListMap(); assertTrue(map.isEmpty()); map.put(m1, "A"); map.put(m5, "E"); map.put(m3, "C"); map.put(m2, "B"); map.put(m4, "D"); assertFalse(map.isEmpty()); assertEquals(5, map.size()); return map.descendingMap(); }
private static ConcurrentNavigableMap dmap0() { ConcurrentSkipListMap map = new ConcurrentSkipListMap(); assertTrue(map.isEmpty()); return map; }
/** Create a map from Integers 1-5 to Strings "A"-"E". */ private static ConcurrentNavigableMap map5() { ConcurrentSkipListMap map = new ConcurrentSkipListMap(); assertTrue(map.isEmpty()); map.put(zero, "Z"); map.put(one, "A"); map.put(five, "E"); map.put(three, "C"); map.put(two, "B"); map.put(four, "D"); map.put(seven, "F"); assertFalse(map.isEmpty()); assertEquals(7, map.size()); return map.subMap(one, true, seven, false); }