parent
01175ec911
commit
0697258b6a
|
@ -61,12 +61,7 @@
|
|||
*/
|
||||
public class MethodUtils {
|
||||
|
||||
private static final Comparator<Method> METHOD_BY_SIGNATURE = new Comparator<Method>() {
|
||||
@Override
|
||||
public int compare(final Method m1, final Method m2) {
|
||||
return m1.toString ().compareTo (m2.toString ());
|
||||
}
|
||||
};
|
||||
private static final Comparator<Method> METHOD_BY_SIGNATURE = (m1, m2) -> m1.toString().compareTo(m2.toString());
|
||||
|
||||
/**
|
||||
* <p>{@link MethodUtils} instances should NOT be constructed in standard programming.
|
||||
|
@ -699,7 +694,7 @@ public static Method getMatchingAccessibleMethod(final Class<?> cls,
|
|||
}
|
||||
|
||||
// Sort methods by signature to force deterministic result
|
||||
Collections.sort (matchingMethods, METHOD_BY_SIGNATURE);
|
||||
Collections.sort(matchingMethods, METHOD_BY_SIGNATURE);
|
||||
|
||||
Method bestMatch = null;
|
||||
for (final Method method : matchingMethods) {
|
||||
|
|
Loading…
Reference in New Issue