Commit 9d3bbdd8c40656001f54d1bc6e419812a8fddf7b
1 parent
9cea44e4
v 1.6.5
Showing
2 changed files
with
3 additions
and
3 deletions
yudao-framework/yudao-common/src/main/java/cn/iocoder/yudao/framework/common/util/object/ObjectUtils.java
| 1 | package cn.iocoder.yudao.framework.common.util.object; | 1 | package cn.iocoder.yudao.framework.common.util.object; |
| 2 | 2 | ||
| 3 | -import cn.hutool.core.util.ArrayUtil; | ||
| 4 | import cn.hutool.core.util.ObjectUtil; | 3 | import cn.hutool.core.util.ObjectUtil; |
| 5 | import cn.hutool.core.util.ReflectUtil; | 4 | import cn.hutool.core.util.ReflectUtil; |
| 6 | 5 | ||
| 7 | import java.lang.reflect.Field; | 6 | import java.lang.reflect.Field; |
| 8 | import java.util.Arrays; | 7 | import java.util.Arrays; |
| 9 | -import java.util.Objects; | ||
| 10 | import java.util.function.Consumer; | 8 | import java.util.function.Consumer; |
| 11 | 9 | ||
| 12 | /** | 10 | /** |
| @@ -47,6 +45,7 @@ public class ObjectUtils { | @@ -47,6 +45,7 @@ public class ObjectUtils { | ||
| 47 | return obj1.compareTo(obj2) > 0 ? obj1 : obj2; | 45 | return obj1.compareTo(obj2) > 0 ? obj1 : obj2; |
| 48 | } | 46 | } |
| 49 | 47 | ||
| 48 | + @SafeVarargs | ||
| 50 | public static <T> T defaultIfNull(T... array) { | 49 | public static <T> T defaultIfNull(T... array) { |
| 51 | for (T item : array) { | 50 | for (T item : array) { |
| 52 | if (item != null) { | 51 | if (item != null) { |
| @@ -56,6 +55,7 @@ public class ObjectUtils { | @@ -56,6 +55,7 @@ public class ObjectUtils { | ||
| 56 | return null; | 55 | return null; |
| 57 | } | 56 | } |
| 58 | 57 | ||
| 58 | + @SafeVarargs | ||
| 59 | public static <T> boolean equalsAny(T obj, T... array) { | 59 | public static <T> boolean equalsAny(T obj, T... array) { |
| 60 | return Arrays.asList(array).contains(obj); | 60 | return Arrays.asList(array).contains(obj); |
| 61 | } | 61 | } |
yudao-ui-admin-vue3/package.json
| 1 | { | 1 | { |
| 2 | "name": "ruoyi-vue-pro-vue3", | 2 | "name": "ruoyi-vue-pro-vue3", |
| 3 | - "version": "1.6.4.1863", | 3 | + "version": "1.6.5.1863", |
| 4 | "description": "基于vue3、vite3、element-plus、typesScript", | 4 | "description": "基于vue3、vite3、element-plus、typesScript", |
| 5 | "author": "xingyu", | 5 | "author": "xingyu", |
| 6 | "private": false, | 6 | "private": false, |