return newList;
}
public final static <S, T> List<Future<T>> transformToFuture(final Iterable<S> sourceList, final ParallelRowConvertor<S, T> convertor) {
final Context context = Context.getCurrentThreadContext();
final Configuration conf = Configuration.getConfiguration();
Boolean isInParallelConverting = context.getData(ParallelListConversionMark);
if (isInParallelConverting != null) {// recursive converting
switch (conf.getParallelRecursivePolicyForListRendering()) {
case EXCEPTION:
throw new RuntimeException(
"Parallel list converting is forbidden (by default) to avoid deadlock. You can change this policy by Configuration.setParallelRecursivePolicyForListRendering().");
case CURRENT_THREAD:
List<T> list = transform(sourceList, (RowConvertor<S, T>) convertor);