Package net.groboclown.retval.impl
Class CollectionUtil
- java.lang.Object
-
- net.groboclown.retval.impl.CollectionUtil
-
public class CollectionUtil extends java.lang.ObjectInternal helper class for working with collections.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<Problem>copyNonNullValues(java.util.Collection<Problem> problems)Performs a copy that enforces the values to be non-null.
-
-
-
Method Detail
-
copyNonNullValues
@Nonnull public static java.util.List<Problem> copyNonNullValues(@Nonnull java.util.Collection<Problem> problems)
Performs a copy that enforces the values to be non-null.This is very similar to the behavior of later JDKs List.copyOf()
- Parameters:
problems- list of problems to copy and enforce non-null entries.- Returns:
- a copy of the parameter, explicitly as a List, and unmodifiable.
-
-