Here you can find the source of copyInto(List
public static <T> void copyInto(List<T> source, List<T> dest)
//package com.java2s; //License from project: Open Source License import java.util.List; public class Main { public static <T> void copyInto(List<T> source, List<T> dest) { dest.clear();/* ww w. j a va2 s . c om*/ for (T obj : source) dest.add(obj); } }