test_class.file: kiji-mapreduce/src/test/java/org/kiji/mapreduce/util/TestLists.java
test_class.identifier: TestLists
test_case.body: @Test
    public void testToArray() {
      String[] oneString = Lists.toArray(Collections.singletonList("foo"), String.class);
      assertEquals(1, oneString.length);
      assertEquals("foo", oneString[0]);
  
      oneString = Lists.toArray(Collections.<String>singletonList(null), String.class);
      assertEquals(1, oneString.length);
      assertNull(oneString[0]);
  
      String[] emptyOut = Lists.toArray(Collections.<String>emptyList(), String.class);
      assertNotNull(emptyOut);
      assertEquals(0, emptyOut.length);
  
      String[] nulOut = Lists.<String>toArray(null, String.class);
      assertNotNull(nulOut);
      assertEquals(0, nulOut.length);
    }
test_case.class_method_signature: TestLists.testToArray()
test_case.full_signature: @Test public void testToArray()
test_case.identifier: testToArray
test_case.invocations: toArray singletonList assertEquals assertEquals toArray singletonList assertEquals assertNull toArray emptyList assertNotNull assertEquals toArray assertNotNull assertEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testToArray()
focal_class.file: kiji-mapreduce/src/main/java/org/kiji/mapreduce/util/Lists.java
focal_class.identifier: Lists
focal_class.class_method_signature: Lists.Lists()
focal_class.full_signature: private  Lists()
focal_class.identifier: Lists
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.signature:  Lists()
focal_class.class_method_signature: Lists.foldLeft(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.full_signature: public static Y foldLeft(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.identifier: foldLeft
focal_class.modifiers: public static
focal_class.parameters: (Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.return: Y
focal_class.signature: Y foldLeft(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.class_method_signature: Lists.foldRight(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.full_signature: public static Y foldRight(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.identifier: foldRight
focal_class.modifiers: public static
focal_class.parameters: (Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.return: Y
focal_class.signature: Y foldRight(Y initial, List<X> inputList, Aggregator<? super X, Y> op)
focal_class.class_method_signature: Lists.map(List<X> inputs, Func<? super X, ? extends Y> mapper)
focal_class.full_signature: public static List<Y> map(List<X> inputs, Func<? super X, ? extends Y> mapper)
focal_class.identifier: map
focal_class.modifiers: public static
focal_class.parameters: (List<X> inputs, Func<? super X, ? extends Y> mapper)
focal_class.return: List<Y>
focal_class.signature: List<Y> map(List<X> inputs, Func<? super X, ? extends Y> mapper)
focal_class.class_method_signature: Lists.toArray(List<X> inputs, Class<X> klazz)
focal_class.full_signature: @SuppressWarnings("unchecked") public static X[] toArray(List<X> inputs, Class<X> klazz)
focal_class.identifier: toArray
focal_class.modifiers: @SuppressWarnings("unchecked") public static
focal_class.parameters: (List<X> inputs, Class<X> klazz)
focal_class.return: X[]
focal_class.signature: X[] toArray(List<X> inputs, Class<X> klazz)
focal_class.class_method_signature: Lists.distinct(List<X> inputs)
focal_class.full_signature: public static List<X> distinct(List<X> inputs)
focal_class.identifier: distinct
focal_class.modifiers: public static
focal_class.parameters: (List<X> inputs)
focal_class.return: List<X>
focal_class.signature: List<X> distinct(List<X> inputs)
focal_method.body: @SuppressWarnings("unchecked")
    public static <X> X[] toArray(List<X> inputs, Class<X> klazz) {
      if (null == inputs) {
        return (X[]) Array.newInstance(klazz, 0);
      }
  
      X[] out = inputs.toArray((X[]) Array.newInstance(klazz, inputs.size()));
      return out;
    }
focal_method.class_method_signature: Lists.toArray(List<X> inputs, Class<X> klazz)
focal_method.full_signature: @SuppressWarnings("unchecked") public static X[] toArray(List<X> inputs, Class<X> klazz)
focal_method.identifier: toArray
focal_method.invocations: newInstance toArray newInstance size
focal_method.modifiers: @SuppressWarnings("unchecked") public static
focal_method.parameters: (List<X> inputs, Class<X> klazz)
focal_method.return: X[]
focal_method.signature: X[] toArray(List<X> inputs, Class<X> klazz)