|
@@ -541,7 +541,7 @@ public final class ObjectUtils {
|
|
|
boolean continuing = true;
|
|
|
do {
|
|
|
Field[] fields = CLASS_FIELD_MAPPING.computeIfAbsent(
|
|
|
- clazz, c -> ObjectUtils.ifNull(c.getDeclaredFields(), () -> new Field[0])
|
|
|
+ clazz, c -> ifNull(c.getDeclaredFields(), () -> new Field[0])
|
|
|
);
|
|
|
for (Field field : fields) {
|
|
|
if (!Modifier.isStatic(field.getModifiers()) && !field.getName().startsWith("this$")) {
|
|
@@ -977,7 +977,7 @@ public final class ObjectUtils {
|
|
|
buffer.append(analyse(parameterized.getRawType()));
|
|
|
java.lang.reflect.Type[] args = parameterized.getActualTypeArguments();
|
|
|
buffer.append(", new ").append(java.lang.reflect.Type.class.getName()).append("[]{");
|
|
|
- if (ObjectUtils.notEmpty(args)) {
|
|
|
+ if (notEmpty(args)) {
|
|
|
for (int i = 0; i < args.length; i++) {
|
|
|
if (i > 0) {
|
|
|
buffer.append(", ");
|
|
@@ -999,11 +999,11 @@ public final class ObjectUtils {
|
|
|
public static List<java.lang.reflect.Type> getGenericSuperclasses(@NonNull Class<?> clazz) {
|
|
|
java.lang.reflect.Type superclass = clazz.getGenericSuperclass();
|
|
|
java.lang.reflect.Type[] interfaces = clazz.getGenericInterfaces();
|
|
|
- if (superclass == null && ObjectUtils.isEmpty(interfaces)) {
|
|
|
+ if (superclass == null && isEmpty(interfaces)) {
|
|
|
return Collections.emptyList();
|
|
|
} else if (superclass == null) {
|
|
|
return Arrays.asList(interfaces);
|
|
|
- } else if (ObjectUtils.isEmpty(interfaces)) {
|
|
|
+ } else if (isEmpty(interfaces)) {
|
|
|
return Collections.singletonList(superclass);
|
|
|
}
|
|
|
List<java.lang.reflect.Type> superclasses = Lists.newArrayList(interfaces);
|
|
@@ -1050,7 +1050,7 @@ public final class ObjectUtils {
|
|
|
java.lang.reflect.Type supered = lookupGenericSuperclass(clazz, superclass);
|
|
|
if (supered instanceof ParameterizedType) {
|
|
|
java.lang.reflect.Type[] arguments = ((ParameterizedType) supered).getActualTypeArguments();
|
|
|
- return ObjectUtils.isEmpty(arguments) ? Object.class : arguments[0];
|
|
|
+ return isEmpty(arguments) ? Object.class : arguments[0];
|
|
|
}
|
|
|
return Object.class;
|
|
|
}
|