mirror of
https://github.com/VibedByKaKi/alexandroid.git
synced 2026-12-03 03:00:23 +01:00
70 lines
2.1 KiB
Java
70 lines
2.1 KiB
Java
package androidx.biometric;
|
|
|
|
import android.content.Context;
|
|
import android.os.Build;
|
|
import androidx.annotation.NonNull;
|
|
|
|
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
|
|
/* loaded from: classes.dex */
|
|
class DeviceUtils {
|
|
private DeviceUtils() {
|
|
}
|
|
|
|
public static boolean canAssumeStrongBiometrics(@NonNull Context context, String str) {
|
|
if (Build.VERSION.SDK_INT >= 30) {
|
|
return false;
|
|
}
|
|
return isModelInList(context, str, R.array.assume_strong_biometrics_models);
|
|
}
|
|
|
|
private static boolean isModelInList(@NonNull Context context, String str, int i) {
|
|
if (str == null) {
|
|
return false;
|
|
}
|
|
for (String str2 : context.getResources().getStringArray(i)) {
|
|
if (str.equals(str2)) {
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
|
|
private static boolean isModelInPrefixList(@NonNull Context context, String str, int i) {
|
|
if (str == null) {
|
|
return false;
|
|
}
|
|
for (String str2 : context.getResources().getStringArray(i)) {
|
|
if (str.startsWith(str2)) {
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
|
|
private static boolean isVendorInList(@NonNull Context context, String str, int i) {
|
|
if (str == null) {
|
|
return false;
|
|
}
|
|
for (String str2 : context.getResources().getStringArray(i)) {
|
|
if (str.equalsIgnoreCase(str2)) {
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
|
|
public static boolean shouldDelayShowingPrompt(@NonNull Context context, String str) {
|
|
if (Build.VERSION.SDK_INT != 29) {
|
|
return false;
|
|
}
|
|
return isModelInList(context, str, R.array.delay_showing_prompt_models);
|
|
}
|
|
|
|
public static boolean shouldHideFingerprintDialog(@NonNull Context context, String str) {
|
|
return false;
|
|
}
|
|
|
|
public static boolean shouldUseFingerprintForCrypto(@NonNull Context context, String str, String str2) {
|
|
return false;
|
|
}
|
|
}
|