Java Utililty Methods Array to List

List of utility methods to do Array to List

Description

The list of methods to do Array to List are organized into topic(s).

Method

java.util.ListtoList(T[] arr)
to List
java.util.List<T> rel = null;
if (arr != null && arr.length > 0) {
    rel = new java.util.ArrayList<T>();
    for (T item : arr) {
        rel.add(item);
return rel;
...
ListtoList(T[] array)
Converts an array to a List .
final List<T> result = new ArrayList<T>(array.length);
for (final T element : array) {
    result.add(element);
return result;
ListtoList(T[] array)
to List
List<T> result = new ArrayList<>(array.length);
for (T o : array) {
    result.add(o);
return result;
ListtoList(T[] array)
to List
ArrayList<T> toRet = new ArrayList<T>();
Collections.addAll(toRet, array);
return toRet;
ListtoList(T[] array)
to List
return Arrays.asList(array);
ListtoList(T[] array)
to List
List<T> list = new ArrayList<>();
Collections.addAll(list, array);
return list;
ListtoList(U... array)
Converts an array into a list.
List<T> result = new ArrayList<T>(array.length);
for (T item : array)
    result.add(item);
return result;
ListtoList(V... elements)
to List
return toList(new ArrayList<V>(), elements);
ListtoList(Value... values)
Create a list
List<Value> list = new ArrayList<>();
if (values != null && values.length > 0) {
    for (Value value : values) {
        list.add(value);
return list;