@NonNull
  public static <T> List<T> immutableCopyOf(@Nullable List<T> list) {
    if (isNullOrEmpty(list)) {
      return Collections.emptyList();
    }
    return Collections.unmodifiableList(new ArrayList<>(list));
  }
@ NonNull public static < T > List < T > immutableCopyOf ( @ Nullable List < T > list ) { if ( isNullOrEmpty ( list ) ) { return Collections . emptyList ( ) ; } return Collections . unmodifiableList ( new ArrayList < > ( list ) ) ; }
Returns an immutable copy of the provided list.