Java List Create CreateObjectList(Object... values)

Here you can find the source of CreateObjectList(Object... values)

Description

Creates a list of objects from an array of objects.

License

Open Source License

Parameter

Parameter Description
values Array of objects

Return

List of objects

Declaration

public static ArrayList CreateObjectList(Object... values) 

Method Source Code


//package com.java2s;
// it under the terms of the GNU General Public License as published by

import java.util.*;

public class Main {
    /** Creates a list of objects from an array of objects.
     *//from ww  w .  j  a v  a2s .  c o m
     * @param values Array of objects
     * @return List of objects
     */
    public static ArrayList CreateObjectList(Object... values) {
        ArrayList results = new ArrayList();
        Collections.addAll(results, values);
        return results;
    }
}

Related

  1. createNewList(Class type)
  2. createNormalDistributionByBootstrapping( List values1, List values2, final List sums1, final List sums2)
  3. createNormativeTroopAllocation( List probs)
  4. createNullElementList(int size)
  5. createNullList(int numberOfElements)
  6. createOneElementList(T element)
  7. createOrderedQuery(String attributeName, List ids)
  8. createOrgAttributeList()
  9. createOrGrow(List list, int minCapacity)