Java Array to List toList(Object[] array)

Here you can find the source of toList(Object[] array)

Description

to List

License

Open Source License

Declaration

public static List toList(Object[] array) 

Method Source Code


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

public class Main {

    public static List toList(Object[] array) {
        ArrayList list = new ArrayList();
        for (int i = 0; i < array.length; i++) {
            list.add(array[i]);// ww w  . j  av  a  2s . c om
        }
        return list;
    }
}

Related

  1. toList(int[] arr)
  2. toList(int[] array)
  3. toList(int[] array)
  4. toList(int[] from)
  5. toList(Object[] arr)
  6. toList(Object[] array)
  7. toList(Object[] array)
  8. toList(Object[] array)
  9. toList(Object[] array)