This commit is contained in:
Looly 2024-11-04 18:12:36 +08:00
parent 96ad2ed57f
commit 00fac9d39a
3 changed files with 6 additions and 6 deletions

View File

@ -75,7 +75,7 @@ public class PathMover {
}
this.src = src;
this.target = Assert.notNull(target, "Target path must be not null !");
this.options = ObjUtil.defaultIfNull(options, new CopyOption[]{});
this.options = ObjUtil.defaultIfNull(options, () -> new CopyOption[]{});
}
/**

View File

@ -77,7 +77,7 @@ public class UrlPath {
* @return 节点列表
*/
public List<CharSequence> getSegments() {
return ObjUtil.defaultIfNull(this.segments, ListUtil.empty());
return ObjUtil.defaultIfNull(this.segments, ListUtil::empty);
}
/**

View File

@ -406,7 +406,7 @@ public class TypeUtil {
if (null == field) {
return null;
}
return getActualType(ObjUtil.defaultIfNull(type, field.getDeclaringClass()), field.getGenericType());
return getActualType(ObjUtil.defaultIfNull(type, field::getDeclaringClass), field.getGenericType());
}
/**