Java List from Array arrayToList(T array[])

Here you can find the source of arrayToList(T array[])

Description

array To List

License

Open Source License

Declaration

public static <T> ArrayList<T> arrayToList(T array[]) 

Method Source Code


//package com.java2s;
import java.util.ArrayList;
import java.util.Arrays;

public class Main {
    public static <T> ArrayList<T> arrayToList(T array[]) {
        if (null == array) {
            return null;
        }//from   ww  w  .  j a va  2  s .  c  om
        return new ArrayList<T>(Arrays.asList(array));
    }
}

Related

  1. arrayToList(Object[] hyCycles)
  2. arrayToList(String[] array, String... defaults)
  3. arrayToList(String[] arrValues)
  4. ArrayToList(String[] input)
  5. arrayToList(String[] str)
  6. arrayToList(T[] array)
  7. arrayToList(T[] array)
  8. arrayToList(T[] array)
  9. arrayToList(T[] array)