Here you can find the source of createList(Object... objs)
@SuppressWarnings("rawtypes") public static List<?> createList(Object... objs)
//package com.java2s; import java.util.ArrayList; import java.util.List; public class Main { @SuppressWarnings("rawtypes") public static List<?> createList(Object... objs) { return createList(new ArrayList(), objs); }//from ww w. j av a 2 s . c om @SuppressWarnings({ "rawtypes", "unchecked" }) public static List<?> createList(List list, Object... objs) { if (objs != null) { for (Object obj : objs) { list.add(obj); } } return list; } }