public static <K, U> Map<K, U> toMap(final Collection<U> list, final Function<? super U, ? extends K> function) {
        return toMap(list, function, Function.identity());
    }
list to map.<br>
if element is null it filters.

@param list     list
@param function map fun
@param <K>      map key type
@param <U>      map value type
@return list
shenyu-common/src/main/java/org/apache/shenyu/common/utils/ListUtil.java