Here you can find the source of add(List
public static void add(List<Object> list, Object[] array)
//package com.java2s; /******************************************************************************* * Copyright (c) 2011 R?diger Herrmann and others. All rights reserved. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors://from w w w .j av a2s . c o m * R?diger Herrmann - initial API and implementation ******************************************************************************/ import java.util.Arrays; import java.util.List; public class Main { public static void add(List<Object> list, Object[] array) { list.addAll(Arrays.asList(array)); } }