Here you can find the source of copyNullable(List extends T> original)
public static <T> List<T> copyNullable(List<? extends T> original)
//package com.java2s; //License from project: Open Source License import java.util.ArrayList; import java.util.List; public class Main { public static <T> List<T> copyNullable(List<? extends T> original) { if (original == null) { return null; }/*from w w w . j a v a 2 s . com*/ return new ArrayList<>(original); } }