Here you can find the source of createList(List
public static <T> List<T> createList(List<T> list)
//package com.java2s; //License from project: Apache License import java.util.ArrayList; import java.util.List; public class Main { public static <T> List<T> createList(List<T> list) { if (list == null) { return null; }/*from w w w . ja v a2 s . c o m*/ List<T> result = new ArrayList<T>(); for (int i = 0; i < list.size(); i++) { T t = list.get(i); result.add(t); } return result; } }