コード例 #1
1
 static List populatedArray(int n) {
   List a = ParallelArray.createEmpty(n, Object.class, ParallelArray.defaultExecutor()).asList();
   assertTrue(a.isEmpty());
   for (int i = 0; i < n; ++i) a.add(new Integer(i));
   assertFalse(a.isEmpty());
   assertEquals(n, a.size());
   return a;
 }
コード例 #2
0
 /** a new list is empty */
 public void testConstructor() {
   List a = ParallelArray.createEmpty(1, Object.class, ParallelArray.defaultExecutor()).asList();
   assertTrue(a.isEmpty());
 }
コード例 #3
0
 static List emptyArray() {
   List a = ParallelArray.createEmpty(1, Object.class, ParallelArray.defaultExecutor()).asList();
   return a;
 }