Java tutorial
//package com.java2s; import java.util.ArrayList; import java.util.Arrays; public class Main { /** * create list from array * * @param <T> * @param values * @return array values in list */ public static <T> ArrayList<T> fromArray(T... values) { ArrayList<T> list = new ArrayList<T>(); list.addAll(Arrays.asList(values)); return list; } }