类 SupplierUtils
java.lang.Object
cn.taketoday.util.function.SupplierUtils
Convenience utilities for
Supplier handling.- 从以下版本开始:
- 4.0 2022/3/9 20:55
- 作者:
- Juergen Hoeller, Harry Yang
- 另请参阅:
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static ObjectResolve a givenSupplier, getting its result or immediately returning the given Object as-is if not aSupplier.static <T> TResolve the givenSupplier, getting its result or immediately returningnullif the supplier itself wasnull.
-
构造器详细资料
-
SupplierUtils
public SupplierUtils()
-
-
方法详细资料
-
resolve
Resolve the givenSupplier, getting its result or immediately returningnullif the supplier itself wasnull.- 参数:
supplier- the supplier to resolve- 返回:
- the supplier's result, or
nullif none
-
resolve
Resolve a givenSupplier, getting its result or immediately returning the given Object as-is if not aSupplier.- 参数:
candidate- the candidate to resolve (potentially aSupplier)- 返回:
- a supplier's result or the given Object as-is
-