35 lines
988 B
Java
35 lines
988 B
Java
package io.github.inflationx.calligraphy3;
|
|
|
|
import java.lang.reflect.InvocationTargetException;
|
|
import java.lang.reflect.Method;
|
|
|
|
/* loaded from: classes6.dex */
|
|
class ReflectionUtils {
|
|
private static final String TAG = "ReflectionUtils";
|
|
|
|
ReflectionUtils() {
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static Method getMethod(Class cls, String str) {
|
|
for (Method method : cls.getMethods()) {
|
|
if (method.getName().equals(str)) {
|
|
method.setAccessible(true);
|
|
return method;
|
|
}
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void invokeMethod(Object obj, Method method, Object... objArr) {
|
|
if (method == null) {
|
|
return;
|
|
}
|
|
try {
|
|
method.invoke(obj, objArr);
|
|
} catch (IllegalAccessException | InvocationTargetException unused) {
|
|
}
|
|
}
|
|
}
|