Java tutorial
//package com.java2s; import java.util.*; import java.util.concurrent.CopyOnWriteArrayList; public class Main { public static <T> List<T> toConcurrentList(Iterable<T> iterable) { List<T> temp = new CopyOnWriteArrayList<>(); iterable.forEach(temp::add); return temp; } }