- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
868 lines
44 KiB
Java
868 lines
44 KiB
Java
package androidx.credentials.provider;
|
|
|
|
import android.annotation.SuppressLint;
|
|
import android.app.PendingIntent;
|
|
import android.app.slice.Slice;
|
|
import android.app.slice.SliceItem;
|
|
import android.app.slice.SliceSpec;
|
|
import android.content.Context;
|
|
import android.graphics.drawable.Icon;
|
|
import android.net.Uri;
|
|
import android.os.Build;
|
|
import android.os.Bundle;
|
|
import android.os.Parcelable;
|
|
import androidx.annotation.RequiresApi;
|
|
import androidx.annotation.RestrictTo;
|
|
import androidx.credentials.CredentialOption;
|
|
import androidx.credentials.PasswordCredential;
|
|
import androidx.credentials.R;
|
|
import androidx.credentials.provider.BeginGetPasswordOption;
|
|
import androidx.credentials.provider.utils.CryptoObjectUtils;
|
|
import java.time.Instant;
|
|
import java.util.Collections;
|
|
import java.util.Iterator;
|
|
import java.util.List;
|
|
import kotlin.collections.CollectionsKt__CollectionsJVMKt;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
import kotlin.jvm.internal.SourceDebugExtension;
|
|
|
|
@RequiresApi(23)
|
|
@SourceDebugExtension({"SMAP\nPasswordCredentialEntry.kt\nKotlin\n*S Kotlin\n*F\n+ 1 PasswordCredentialEntry.kt\nandroidx/credentials/provider/PasswordCredentialEntry\n+ 2 fake.kt\nkotlin/jvm/internal/FakeKt\n*L\n1#1,899:1\n1#2:900\n*E\n"})
|
|
/* loaded from: classes.dex */
|
|
public final class PasswordCredentialEntry extends CredentialEntry {
|
|
public static final Companion Companion = new Companion(null);
|
|
private static final String TAG = "PasswordCredentialEntry";
|
|
private final CharSequence displayName;
|
|
private final Icon icon;
|
|
private final boolean isAutoSelectAllowed;
|
|
private final boolean isAutoSelectAllowedFromOption;
|
|
private boolean isCreatedFromSlice;
|
|
private boolean isDefaultIconFromSlice;
|
|
private final Instant lastUsedTime;
|
|
private final PendingIntent pendingIntent;
|
|
private final CharSequence typeDisplayName;
|
|
private final CharSequence username;
|
|
|
|
public static final PasswordCredentialEntry fromCredentialEntry(android.service.credentials.CredentialEntry credentialEntry) {
|
|
return Companion.fromCredentialEntry(credentialEntry);
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final PasswordCredentialEntry fromSlice(Slice slice) {
|
|
return Companion.fromSlice(slice);
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final Slice toSlice(PasswordCredentialEntry passwordCredentialEntry) {
|
|
return Companion.toSlice(passwordCredentialEntry);
|
|
}
|
|
|
|
public final CharSequence getDisplayName() {
|
|
return this.displayName;
|
|
}
|
|
|
|
public final Icon getIcon() {
|
|
return this.icon;
|
|
}
|
|
|
|
public final Instant getLastUsedTime() {
|
|
return this.lastUsedTime;
|
|
}
|
|
|
|
public final PendingIntent getPendingIntent() {
|
|
return this.pendingIntent;
|
|
}
|
|
|
|
public final CharSequence getTypeDisplayName() {
|
|
return this.typeDisplayName;
|
|
}
|
|
|
|
public final CharSequence getUsername() {
|
|
return this.username;
|
|
}
|
|
|
|
public final boolean isAutoSelectAllowed() {
|
|
return this.isAutoSelectAllowed;
|
|
}
|
|
|
|
public final boolean isAutoSelectAllowedFromOption() {
|
|
return this.isAutoSelectAllowedFromOption;
|
|
}
|
|
|
|
public /* synthetic */ PasswordCredentialEntry(CharSequence charSequence, CharSequence charSequence2, CharSequence charSequence3, PendingIntent pendingIntent, Instant instant, Icon icon, boolean z, BeginGetPasswordOption beginGetPasswordOption, boolean z2, CharSequence charSequence4, CharSequence charSequence5, BiometricPromptData biometricPromptData, boolean z3, boolean z4, boolean z5, int i, DefaultConstructorMarker defaultConstructorMarker) {
|
|
this(charSequence, charSequence2, charSequence3, pendingIntent, instant, icon, z, beginGetPasswordOption, z2, (i & 512) != 0 ? charSequence : charSequence4, (i & 1024) != 0 ? null : charSequence5, (i & 2048) != 0 ? null : biometricPromptData, (i & 4096) != 0 ? CredentialOption.Companion.extractAutoSelectValue$credentials_release(beginGetPasswordOption.getCandidateQueryData()) : z3, (i & 8192) != 0 ? false : z4, (i & 16384) != 0 ? false : z5);
|
|
}
|
|
|
|
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
|
public PasswordCredentialEntry(CharSequence username, CharSequence charSequence, CharSequence typeDisplayName, PendingIntent pendingIntent, Instant instant, Icon icon, boolean z, BeginGetPasswordOption beginGetPasswordOption, boolean z2, CharSequence charSequence2, CharSequence charSequence3, BiometricPromptData biometricPromptData, boolean z3, boolean z4, boolean z5) {
|
|
super(PasswordCredential.TYPE_PASSWORD_CREDENTIAL, beginGetPasswordOption, charSequence2 == null ? username : charSequence2, z2, charSequence3, biometricPromptData);
|
|
Intrinsics.checkNotNullParameter(username, "username");
|
|
Intrinsics.checkNotNullParameter(typeDisplayName, "typeDisplayName");
|
|
Intrinsics.checkNotNullParameter(pendingIntent, "pendingIntent");
|
|
Intrinsics.checkNotNullParameter(icon, "icon");
|
|
Intrinsics.checkNotNullParameter(beginGetPasswordOption, "beginGetPasswordOption");
|
|
this.username = username;
|
|
this.displayName = charSequence;
|
|
this.typeDisplayName = typeDisplayName;
|
|
this.pendingIntent = pendingIntent;
|
|
this.lastUsedTime = instant;
|
|
this.icon = icon;
|
|
this.isAutoSelectAllowed = z;
|
|
this.isCreatedFromSlice = z4;
|
|
this.isDefaultIconFromSlice = z5;
|
|
this.isAutoSelectAllowedFromOption = z3;
|
|
if (username.length() <= 0) {
|
|
throw new IllegalArgumentException("username must not be empty".toString());
|
|
}
|
|
}
|
|
|
|
public final boolean hasDefaultIcon() {
|
|
if (Build.VERSION.SDK_INT >= 28) {
|
|
return Api28Impl.isDefaultIcon(this);
|
|
}
|
|
return false;
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public /* synthetic */ PasswordCredentialEntry(android.content.Context r15, java.lang.CharSequence r16, android.app.PendingIntent r17, androidx.credentials.provider.BeginGetPasswordOption r18, java.lang.CharSequence r19, java.time.Instant r20, android.graphics.drawable.Icon r21, boolean r22, java.lang.CharSequence r23, boolean r24, int r25, kotlin.jvm.internal.DefaultConstructorMarker r26) {
|
|
/*
|
|
r14 = this;
|
|
r0 = r25
|
|
r1 = r0 & 16
|
|
r2 = 0
|
|
if (r1 == 0) goto L9
|
|
r8 = r2
|
|
goto Lb
|
|
L9:
|
|
r8 = r19
|
|
Lb:
|
|
r1 = r0 & 32
|
|
if (r1 == 0) goto L11
|
|
r9 = r2
|
|
goto L13
|
|
L11:
|
|
r9 = r20
|
|
L13:
|
|
r1 = r0 & 64
|
|
if (r1 == 0) goto L25
|
|
int r1 = androidx.credentials.R.drawable.ic_password
|
|
r4 = r15
|
|
android.graphics.drawable.Icon r1 = android.graphics.drawable.Icon.createWithResource(r15, r1)
|
|
java.lang.String r3 = "createWithResource(conte…, R.drawable.ic_password)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r1, r3)
|
|
r10 = r1
|
|
goto L28
|
|
L25:
|
|
r4 = r15
|
|
r10 = r21
|
|
L28:
|
|
r1 = r0 & 128(0x80, float:1.8E-43)
|
|
r3 = 0
|
|
if (r1 == 0) goto L2f
|
|
r11 = r3
|
|
goto L31
|
|
L2f:
|
|
r11 = r22
|
|
L31:
|
|
r1 = r0 & 256(0x100, float:3.59E-43)
|
|
if (r1 == 0) goto L37
|
|
r12 = r2
|
|
goto L39
|
|
L37:
|
|
r12 = r23
|
|
L39:
|
|
r0 = r0 & 512(0x200, float:7.17E-43)
|
|
if (r0 == 0) goto L3f
|
|
r13 = r3
|
|
goto L41
|
|
L3f:
|
|
r13 = r24
|
|
L41:
|
|
r3 = r14
|
|
r4 = r15
|
|
r5 = r16
|
|
r6 = r17
|
|
r7 = r18
|
|
r3.<init>(r4, r5, r6, r7, r8, r9, r10, r11, r12, r13)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean, java.lang.CharSequence, boolean, int, kotlin.jvm.internal.DefaultConstructorMarker):void");
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public PasswordCredentialEntry(android.content.Context r20, java.lang.CharSequence r21, android.app.PendingIntent r22, androidx.credentials.provider.BeginGetPasswordOption r23, java.lang.CharSequence r24, java.time.Instant r25, android.graphics.drawable.Icon r26, boolean r27, java.lang.CharSequence r28, boolean r29) {
|
|
/*
|
|
r19 = this;
|
|
r0 = r20
|
|
r1 = r19
|
|
r2 = r21
|
|
r5 = r22
|
|
r9 = r23
|
|
r3 = r24
|
|
r6 = r25
|
|
r7 = r26
|
|
r8 = r27
|
|
r12 = r28
|
|
r10 = r29
|
|
java.lang.String r4 = "context"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r0, r4)
|
|
java.lang.String r4 = "username"
|
|
r11 = r21
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "pendingIntent"
|
|
r11 = r22
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "beginGetPasswordOption"
|
|
r11 = r23
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "icon"
|
|
r11 = r26
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
int r4 = androidx.credentials.R.string.android_credentials_TYPE_PASSWORD_CREDENTIAL
|
|
java.lang.String r0 = r0.getString(r4)
|
|
r4 = r0
|
|
java.lang.String r11 = "context.getString(R.stri…TYPE_PASSWORD_CREDENTIAL)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r0, r11)
|
|
r11 = 0
|
|
r13 = 0
|
|
r14 = 0
|
|
r15 = 0
|
|
r16 = 0
|
|
r17 = 31232(0x7a00, float:4.3765E-41)
|
|
r18 = 0
|
|
r1.<init>(r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17, r18)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean, java.lang.CharSequence, boolean):void");
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public /* synthetic */ PasswordCredentialEntry(android.content.Context r16, java.lang.CharSequence r17, android.app.PendingIntent r18, androidx.credentials.provider.BeginGetPasswordOption r19, java.lang.CharSequence r20, java.time.Instant r21, android.graphics.drawable.Icon r22, boolean r23, java.lang.CharSequence r24, boolean r25, androidx.credentials.provider.BiometricPromptData r26, int r27, kotlin.jvm.internal.DefaultConstructorMarker r28) {
|
|
/*
|
|
r15 = this;
|
|
r0 = r27
|
|
r1 = r0 & 16
|
|
r2 = 0
|
|
if (r1 == 0) goto L9
|
|
r8 = r2
|
|
goto Lb
|
|
L9:
|
|
r8 = r20
|
|
Lb:
|
|
r1 = r0 & 32
|
|
if (r1 == 0) goto L11
|
|
r9 = r2
|
|
goto L13
|
|
L11:
|
|
r9 = r21
|
|
L13:
|
|
r1 = r0 & 64
|
|
if (r1 == 0) goto L26
|
|
int r1 = androidx.credentials.R.drawable.ic_password
|
|
r4 = r16
|
|
android.graphics.drawable.Icon r1 = android.graphics.drawable.Icon.createWithResource(r4, r1)
|
|
java.lang.String r3 = "createWithResource(conte…, R.drawable.ic_password)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r1, r3)
|
|
r10 = r1
|
|
goto L2a
|
|
L26:
|
|
r4 = r16
|
|
r10 = r22
|
|
L2a:
|
|
r1 = r0 & 128(0x80, float:1.8E-43)
|
|
r3 = 0
|
|
if (r1 == 0) goto L31
|
|
r11 = r3
|
|
goto L33
|
|
L31:
|
|
r11 = r23
|
|
L33:
|
|
r1 = r0 & 256(0x100, float:3.59E-43)
|
|
if (r1 == 0) goto L39
|
|
r12 = r2
|
|
goto L3b
|
|
L39:
|
|
r12 = r24
|
|
L3b:
|
|
r1 = r0 & 512(0x200, float:7.17E-43)
|
|
if (r1 == 0) goto L41
|
|
r13 = r3
|
|
goto L43
|
|
L41:
|
|
r13 = r25
|
|
L43:
|
|
r0 = r0 & 1024(0x400, float:1.435E-42)
|
|
if (r0 == 0) goto L49
|
|
r14 = r2
|
|
goto L4b
|
|
L49:
|
|
r14 = r26
|
|
L4b:
|
|
r3 = r15
|
|
r4 = r16
|
|
r5 = r17
|
|
r6 = r18
|
|
r7 = r19
|
|
r3.<init>(r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean, java.lang.CharSequence, boolean, androidx.credentials.provider.BiometricPromptData, int, kotlin.jvm.internal.DefaultConstructorMarker):void");
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
@androidx.annotation.RequiresApi(35)
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public PasswordCredentialEntry(android.content.Context r20, java.lang.CharSequence r21, android.app.PendingIntent r22, androidx.credentials.provider.BeginGetPasswordOption r23, java.lang.CharSequence r24, java.time.Instant r25, android.graphics.drawable.Icon r26, boolean r27, java.lang.CharSequence r28, boolean r29, androidx.credentials.provider.BiometricPromptData r30) {
|
|
/*
|
|
r19 = this;
|
|
r0 = r20
|
|
r1 = r19
|
|
r2 = r21
|
|
r5 = r22
|
|
r9 = r23
|
|
r3 = r24
|
|
r6 = r25
|
|
r7 = r26
|
|
r8 = r27
|
|
r12 = r28
|
|
r10 = r29
|
|
r13 = r30
|
|
java.lang.String r4 = "context"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r0, r4)
|
|
java.lang.String r4 = "username"
|
|
r11 = r21
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "pendingIntent"
|
|
r11 = r22
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "beginGetPasswordOption"
|
|
r11 = r23
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
java.lang.String r4 = "icon"
|
|
r11 = r26
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r11, r4)
|
|
int r4 = androidx.credentials.R.string.android_credentials_TYPE_PASSWORD_CREDENTIAL
|
|
java.lang.String r0 = r0.getString(r4)
|
|
r4 = r0
|
|
java.lang.String r11 = "context.getString(R.stri…TYPE_PASSWORD_CREDENTIAL)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r0, r11)
|
|
r11 = 0
|
|
r14 = 0
|
|
r15 = 0
|
|
r16 = 0
|
|
r17 = 29184(0x7200, float:4.0895E-41)
|
|
r18 = 0
|
|
r1.<init>(r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17, r18)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean, java.lang.CharSequence, boolean, androidx.credentials.provider.BiometricPromptData):void");
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public /* synthetic */ PasswordCredentialEntry(android.content.Context r13, java.lang.CharSequence r14, android.app.PendingIntent r15, androidx.credentials.provider.BeginGetPasswordOption r16, java.lang.CharSequence r17, java.time.Instant r18, android.graphics.drawable.Icon r19, boolean r20, int r21, kotlin.jvm.internal.DefaultConstructorMarker r22) {
|
|
/*
|
|
r12 = this;
|
|
r0 = r21
|
|
r1 = r0 & 16
|
|
r2 = 0
|
|
if (r1 == 0) goto L9
|
|
r8 = r2
|
|
goto Lb
|
|
L9:
|
|
r8 = r17
|
|
Lb:
|
|
r1 = r0 & 32
|
|
if (r1 == 0) goto L11
|
|
r9 = r2
|
|
goto L13
|
|
L11:
|
|
r9 = r18
|
|
L13:
|
|
r1 = r0 & 64
|
|
if (r1 == 0) goto L25
|
|
int r1 = androidx.credentials.R.drawable.ic_password
|
|
r2 = r13
|
|
android.graphics.drawable.Icon r1 = android.graphics.drawable.Icon.createWithResource(r13, r1)
|
|
java.lang.String r3 = "createWithResource(conte…, R.drawable.ic_password)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r1, r3)
|
|
r10 = r1
|
|
goto L28
|
|
L25:
|
|
r2 = r13
|
|
r10 = r19
|
|
L28:
|
|
r0 = r0 & 128(0x80, float:1.8E-43)
|
|
if (r0 == 0) goto L2f
|
|
r0 = 0
|
|
r11 = r0
|
|
goto L31
|
|
L2f:
|
|
r11 = r20
|
|
L31:
|
|
r3 = r12
|
|
r4 = r13
|
|
r5 = r14
|
|
r6 = r15
|
|
r7 = r16
|
|
r3.<init>(r4, r5, r6, r7, r8, r9, r10, r11)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean, int, kotlin.jvm.internal.DefaultConstructorMarker):void");
|
|
}
|
|
|
|
/* JADX WARN: Illegal instructions before constructor call */
|
|
/*
|
|
Code decompiled incorrectly, please refer to instructions dump.
|
|
To view partially-correct add '--show-bad-code' argument
|
|
*/
|
|
public /* synthetic */ PasswordCredentialEntry(android.content.Context r20, java.lang.CharSequence r21, android.app.PendingIntent r22, androidx.credentials.provider.BeginGetPasswordOption r23, java.lang.CharSequence r24, java.time.Instant r25, android.graphics.drawable.Icon r26, boolean r27) {
|
|
/*
|
|
r19 = this;
|
|
r0 = r20
|
|
r1 = r19
|
|
r2 = r21
|
|
r5 = r22
|
|
r9 = r23
|
|
r3 = r24
|
|
r6 = r25
|
|
r7 = r26
|
|
r8 = r27
|
|
java.lang.String r4 = "context"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r0, r4)
|
|
java.lang.String r4 = "username"
|
|
r10 = r21
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r10, r4)
|
|
java.lang.String r4 = "pendingIntent"
|
|
r10 = r22
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r10, r4)
|
|
java.lang.String r4 = "beginGetPasswordOption"
|
|
r10 = r23
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r10, r4)
|
|
java.lang.String r4 = "icon"
|
|
r10 = r26
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r10, r4)
|
|
int r4 = androidx.credentials.R.string.android_credentials_TYPE_PASSWORD_CREDENTIAL
|
|
java.lang.String r0 = r0.getString(r4)
|
|
r4 = r0
|
|
java.lang.String r10 = "context.getString(R.stri…TYPE_PASSWORD_CREDENTIAL)"
|
|
kotlin.jvm.internal.Intrinsics.checkNotNullExpressionValue(r0, r10)
|
|
r10 = 0
|
|
r11 = 0
|
|
r12 = 0
|
|
r13 = 0
|
|
r14 = 0
|
|
r15 = 0
|
|
r16 = 0
|
|
r17 = 32256(0x7e00, float:4.52E-41)
|
|
r18 = 0
|
|
r1.<init>(r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17, r18)
|
|
return
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: androidx.credentials.provider.PasswordCredentialEntry.<init>(android.content.Context, java.lang.CharSequence, android.app.PendingIntent, androidx.credentials.provider.BeginGetPasswordOption, java.lang.CharSequence, java.time.Instant, android.graphics.drawable.Icon, boolean):void");
|
|
}
|
|
|
|
@RequiresApi(34)
|
|
public static final class Api34Impl {
|
|
public static final Api34Impl INSTANCE = new Api34Impl();
|
|
|
|
private Api34Impl() {
|
|
}
|
|
|
|
public static final PasswordCredentialEntry fromCredentialEntry(android.service.credentials.CredentialEntry credentialEntry) {
|
|
Intrinsics.checkNotNullParameter(credentialEntry, "credentialEntry");
|
|
Slice slice = credentialEntry.getSlice();
|
|
Intrinsics.checkNotNullExpressionValue(slice, "credentialEntry.slice");
|
|
return PasswordCredentialEntry.Companion.fromSlice(slice);
|
|
}
|
|
}
|
|
|
|
@RequiresApi(35)
|
|
@SourceDebugExtension({"SMAP\nPasswordCredentialEntry.kt\nKotlin\n*S Kotlin\n*F\n+ 1 PasswordCredentialEntry.kt\nandroidx/credentials/provider/PasswordCredentialEntry$Api35Impl\n+ 2 _Collections.kt\nkotlin/collections/CollectionsKt___CollectionsKt\n*L\n1#1,899:1\n1855#2,2:900\n*S KotlinDebug\n*F\n+ 1 PasswordCredentialEntry.kt\nandroidx/credentials/provider/PasswordCredentialEntry$Api35Impl\n*L\n383#1:900,2\n*E\n"})
|
|
public static final class Api35Impl {
|
|
public static final Api35Impl INSTANCE = new Api35Impl();
|
|
|
|
private Api35Impl() {
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final Slice toSlice(PasswordCredentialEntry entry) {
|
|
Slice build;
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
String type = entry.getType();
|
|
Action$Companion$$ExternalSyntheticApiModelOutline12.m();
|
|
Slice.Builder m = Action$Companion$$ExternalSyntheticApiModelOutline10.m(Uri.EMPTY, Action$Companion$$ExternalSyntheticApiModelOutline9.m(type, 1));
|
|
Api28Impl.INSTANCE.addToSlice(entry, m);
|
|
INSTANCE.addToSlice(entry, m);
|
|
build = m.build();
|
|
Intrinsics.checkNotNullExpressionValue(build, "sliceBuilder.build()");
|
|
return build;
|
|
}
|
|
|
|
public final void addToSlice(PasswordCredentialEntry entry, Slice.Builder sliceBuilder) {
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
Intrinsics.checkNotNullParameter(sliceBuilder, "sliceBuilder");
|
|
BiometricPromptData biometricPromptData = entry.getBiometricPromptData();
|
|
if (biometricPromptData != null) {
|
|
sliceBuilder.addInt(biometricPromptData.getAllowedAuthenticators(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_ALLOWED_AUTHENTICATORS));
|
|
if (biometricPromptData.getCryptoObject() != null) {
|
|
sliceBuilder.addLong(CryptoObjectUtils.INSTANCE.getOperationHandle(biometricPromptData.getCryptoObject()), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_CRYPTO_OP_ID));
|
|
}
|
|
sliceBuilder.addBundle(BiometricPromptData.Companion.toBundle(biometricPromptData), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_BIOMETRIC_PROMPT_DATA));
|
|
}
|
|
}
|
|
|
|
@SuppressLint({"WrongConstant"})
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final PasswordCredentialEntry fromSlice(Slice slice) {
|
|
List items;
|
|
boolean hasHint;
|
|
Intrinsics.checkNotNullParameter(slice, "slice");
|
|
PasswordCredentialEntry fromSlice = Api28Impl.fromSlice(slice);
|
|
if (fromSlice == null) {
|
|
return null;
|
|
}
|
|
items = slice.getItems();
|
|
Intrinsics.checkNotNullExpressionValue(items, "slice.items");
|
|
Iterator it = items.iterator();
|
|
Bundle bundle = null;
|
|
while (it.hasNext()) {
|
|
SliceItem m = Action$Companion$$ExternalSyntheticApiModelOutline5.m(it.next());
|
|
hasHint = m.hasHint(CredentialEntry.SLICE_HINT_BIOMETRIC_PROMPT_DATA);
|
|
if (hasHint) {
|
|
bundle = m.getBundle();
|
|
}
|
|
}
|
|
try {
|
|
CharSequence username = fromSlice.getUsername();
|
|
CharSequence displayName = fromSlice.getDisplayName();
|
|
CharSequence typeDisplayName = fromSlice.getTypeDisplayName();
|
|
PendingIntent pendingIntent = fromSlice.getPendingIntent();
|
|
Instant lastUsedTime = fromSlice.getLastUsedTime();
|
|
Icon icon = fromSlice.getIcon();
|
|
boolean isAutoSelectAllowed = fromSlice.isAutoSelectAllowed();
|
|
BeginGetCredentialOption beginGetCredentialOption = fromSlice.getBeginGetCredentialOption();
|
|
Intrinsics.checkNotNull(beginGetCredentialOption, "null cannot be cast to non-null type androidx.credentials.provider.BeginGetPasswordOption");
|
|
return new PasswordCredentialEntry(username, displayName, typeDisplayName, pendingIntent, lastUsedTime, icon, isAutoSelectAllowed, (BeginGetPasswordOption) beginGetCredentialOption, fromSlice.isDefaultIconPreferredAsSingleProvider(), fromSlice.getEntryGroupId(), fromSlice.getAffiliatedDomain(), bundle != null ? BiometricPromptData.Companion.fromBundle(bundle) : null, fromSlice.isAutoSelectAllowedFromOption(), true, fromSlice.isDefaultIconFromSlice);
|
|
} catch (Exception e) {
|
|
StringBuilder sb = new StringBuilder();
|
|
sb.append("fromSlice failed with: ");
|
|
sb.append(e.getMessage());
|
|
return null;
|
|
}
|
|
}
|
|
}
|
|
|
|
@RequiresApi(28)
|
|
@SourceDebugExtension({"SMAP\nPasswordCredentialEntry.kt\nKotlin\n*S Kotlin\n*F\n+ 1 PasswordCredentialEntry.kt\nandroidx/credentials/provider/PasswordCredentialEntry$Api28Impl\n+ 2 _Collections.kt\nkotlin/collections/CollectionsKt___CollectionsKt\n*L\n1#1,899:1\n1855#2,2:900\n*S KotlinDebug\n*F\n+ 1 PasswordCredentialEntry.kt\nandroidx/credentials/provider/PasswordCredentialEntry$Api28Impl\n*L\n543#1:900,2\n*E\n"})
|
|
public static final class Api28Impl {
|
|
public static final Api28Impl INSTANCE = new Api28Impl();
|
|
|
|
private Api28Impl() {
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final boolean isDefaultIcon(PasswordCredentialEntry entry) {
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
if (entry.isCreatedFromSlice) {
|
|
return entry.isDefaultIconFromSlice;
|
|
}
|
|
return entry.getIcon().getType() == 2 && entry.getIcon().getResId() == R.drawable.ic_password;
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final Slice toSlice(PasswordCredentialEntry entry) {
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
Slice.Builder builder = new Slice.Builder(Uri.EMPTY, new SliceSpec(entry.getType(), 1));
|
|
INSTANCE.addToSlice(entry, builder);
|
|
Slice build = builder.build();
|
|
Intrinsics.checkNotNullExpressionValue(build, "sliceBuilder.build()");
|
|
return build;
|
|
}
|
|
|
|
public final void addToSlice(PasswordCredentialEntry entry, Slice.Builder sliceBuilder) {
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
Intrinsics.checkNotNullParameter(sliceBuilder, "sliceBuilder");
|
|
BeginGetCredentialOption beginGetCredentialOption = entry.getBeginGetCredentialOption();
|
|
sliceBuilder.addText(beginGetCredentialOption.getId(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_OPTION_ID)).addText(entry.getEntryGroupId(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_DEDUPLICATION_ID)).addText(entry.isDefaultIconPreferredAsSingleProvider() ? "true" : "false", null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_IS_DEFAULT_ICON_PREFERRED)).addText(entry.getAffiliatedDomain(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_AFFILIATED_DOMAIN));
|
|
CharSequence username = entry.getUsername();
|
|
CharSequence displayName = entry.getDisplayName();
|
|
PendingIntent pendingIntent = entry.getPendingIntent();
|
|
CharSequence typeDisplayName = entry.getTypeDisplayName();
|
|
Instant lastUsedTime = entry.getLastUsedTime();
|
|
sliceBuilder.addText(typeDisplayName, null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_TYPE_DISPLAY_NAME)).addText(username, null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_TITLE)).addText(displayName, null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_SUBTITLE)).addText(entry.isAutoSelectAllowed() ? "true" : "false", null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_AUTO_ALLOWED)).addIcon(entry.getIcon(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_ICON));
|
|
try {
|
|
if (entry.hasDefaultIcon()) {
|
|
sliceBuilder.addInt(1, null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_DEFAULT_ICON_RES_ID));
|
|
}
|
|
} catch (IllegalStateException unused) {
|
|
}
|
|
if (entry.isAutoSelectAllowedFromOption()) {
|
|
sliceBuilder.addInt(1, null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_AUTO_SELECT_FROM_OPTION));
|
|
}
|
|
if (lastUsedTime != null) {
|
|
sliceBuilder.addLong(lastUsedTime.toEpochMilli(), null, CollectionsKt__CollectionsJVMKt.listOf(CredentialEntry.SLICE_HINT_LAST_USED_TIME_MILLIS));
|
|
}
|
|
sliceBuilder.addAction(pendingIntent, new Slice.Builder(sliceBuilder).addHints(Collections.singletonList(CredentialEntry.SLICE_HINT_PENDING_INTENT)).build(), null);
|
|
}
|
|
|
|
@SuppressLint({"WrongConstant"})
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public static final PasswordCredentialEntry fromSlice(Slice slice) {
|
|
Intrinsics.checkNotNullParameter(slice, "slice");
|
|
List<SliceItem> items = slice.getItems();
|
|
Intrinsics.checkNotNullExpressionValue(items, "slice.items");
|
|
CharSequence charSequence = null;
|
|
CharSequence charSequence2 = null;
|
|
CharSequence charSequence3 = null;
|
|
PendingIntent pendingIntent = null;
|
|
Instant instant = null;
|
|
Icon icon = null;
|
|
CharSequence charSequence4 = null;
|
|
CharSequence charSequence5 = null;
|
|
boolean z = false;
|
|
boolean z2 = false;
|
|
boolean z3 = false;
|
|
boolean z4 = false;
|
|
CharSequence charSequence6 = null;
|
|
for (SliceItem sliceItem : items) {
|
|
if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_OPTION_ID)) {
|
|
charSequence6 = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_DEDUPLICATION_ID)) {
|
|
charSequence4 = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_IS_DEFAULT_ICON_PREFERRED)) {
|
|
if (Intrinsics.areEqual(sliceItem.getText(), "true")) {
|
|
z2 = true;
|
|
}
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_AFFILIATED_DOMAIN)) {
|
|
charSequence5 = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_TYPE_DISPLAY_NAME)) {
|
|
charSequence3 = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_TITLE)) {
|
|
charSequence = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_SUBTITLE)) {
|
|
charSequence2 = sliceItem.getText();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_ICON)) {
|
|
icon = sliceItem.getIcon();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_PENDING_INTENT)) {
|
|
pendingIntent = sliceItem.getAction();
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_LAST_USED_TIME_MILLIS)) {
|
|
instant = Instant.ofEpochMilli(sliceItem.getLong());
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_AUTO_ALLOWED)) {
|
|
if (Intrinsics.areEqual(sliceItem.getText(), "true")) {
|
|
z = true;
|
|
}
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_AUTO_SELECT_FROM_OPTION)) {
|
|
z3 = true;
|
|
} else if (sliceItem.hasHint(CredentialEntry.SLICE_HINT_DEFAULT_ICON_RES_ID)) {
|
|
z4 = true;
|
|
}
|
|
}
|
|
try {
|
|
Intrinsics.checkNotNull(charSequence);
|
|
Intrinsics.checkNotNull(charSequence3);
|
|
Intrinsics.checkNotNull(pendingIntent);
|
|
Intrinsics.checkNotNull(icon);
|
|
BeginGetPasswordOption.Companion companion = BeginGetPasswordOption.Companion;
|
|
Bundle bundle = new Bundle();
|
|
Intrinsics.checkNotNull(charSequence6);
|
|
return new PasswordCredentialEntry(charSequence, charSequence2, charSequence3, pendingIntent, instant, icon, z, companion.createFrom$credentials_release(bundle, charSequence6.toString()), z2, charSequence4, charSequence5, null, z3, true, z4, 2048, null);
|
|
} catch (Exception e) {
|
|
StringBuilder sb = new StringBuilder();
|
|
sb.append("fromSlice failed with: ");
|
|
sb.append(e.getMessage());
|
|
return null;
|
|
}
|
|
}
|
|
}
|
|
|
|
public static final class Companion {
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
|
|
private Companion() {
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public final Slice toSlice(PasswordCredentialEntry entry) {
|
|
Intrinsics.checkNotNullParameter(entry, "entry");
|
|
int i = Build.VERSION.SDK_INT;
|
|
if (i >= 35) {
|
|
return Api35Impl.toSlice(entry);
|
|
}
|
|
if (i >= 28) {
|
|
return Api28Impl.toSlice(entry);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
@RestrictTo({RestrictTo.Scope.LIBRARY})
|
|
public final PasswordCredentialEntry fromSlice(Slice slice) {
|
|
Intrinsics.checkNotNullParameter(slice, "slice");
|
|
int i = Build.VERSION.SDK_INT;
|
|
if (i >= 35) {
|
|
return Api35Impl.fromSlice(slice);
|
|
}
|
|
if (i >= 28) {
|
|
return Api28Impl.fromSlice(slice);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public final PasswordCredentialEntry fromCredentialEntry(android.service.credentials.CredentialEntry credentialEntry) {
|
|
Intrinsics.checkNotNullParameter(credentialEntry, "credentialEntry");
|
|
if (Build.VERSION.SDK_INT >= 34) {
|
|
return Api34Impl.fromCredentialEntry(credentialEntry);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public final void marshall$credentials_release(PasswordCredentialEntry passwordCredentialEntry, Bundle bundle, int i) {
|
|
Intrinsics.checkNotNullParameter(passwordCredentialEntry, "<this>");
|
|
Intrinsics.checkNotNullParameter(bundle, "bundle");
|
|
CredentialEntry.Companion.marshallCommonProperties$credentials_release(passwordCredentialEntry, bundle, i);
|
|
bundle.putParcelable(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_PENDING_INTENT_PREFIX + i, passwordCredentialEntry.getPendingIntent());
|
|
bundle.putBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_IS_AUTO_SELECT_ALLOWED_PREFIX + i, passwordCredentialEntry.isAutoSelectAllowed());
|
|
bundle.putBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_IS_AUTO_SELECT_ALLOWED_FROM_OPTION_PREFIX + i, passwordCredentialEntry.isAutoSelectAllowedFromOption());
|
|
bundle.putBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_HAS_DEFAULT_ICON_PREFIX + i, passwordCredentialEntry.hasDefaultIcon());
|
|
bundle.putCharSequence(CredentialEntry.EXTRA_CREDENTIAL_TITLE_PREFIX + i, passwordCredentialEntry.getUsername());
|
|
bundle.putCharSequence(CredentialEntry.EXTRA_CREDENTIAL_TYPE_DISPLAY_NAME_PREFIX + i, passwordCredentialEntry.getTypeDisplayName());
|
|
bundle.putParcelable(CredentialEntry.EXTRA_CREDENTIAL_TYPE_ICON_PREFIX + i, passwordCredentialEntry.getIcon());
|
|
CharSequence displayName = passwordCredentialEntry.getDisplayName();
|
|
if (displayName != null) {
|
|
bundle.putCharSequence(CredentialEntry.EXTRA_CREDENTIAL_SUBTITLE_PREFIX + i, displayName);
|
|
}
|
|
Instant lastUsedTime = passwordCredentialEntry.getLastUsedTime();
|
|
if (lastUsedTime != null) {
|
|
bundle.putSerializable(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_LAST_USED_TIME_PREFIX + i, lastUsedTime);
|
|
}
|
|
}
|
|
|
|
public final PasswordCredentialEntry unmarshall$credentials_release(Bundle bundle, int i) {
|
|
Intrinsics.checkNotNullParameter(bundle, "bundle");
|
|
try {
|
|
String string = bundle.getString(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_OPTION_ID_PREFIX + i);
|
|
Intrinsics.checkNotNull(string);
|
|
Bundle bundle2 = bundle.getBundle(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_OPTION_DATA_PREFIX + i);
|
|
Intrinsics.checkNotNull(bundle2);
|
|
CharSequence charSequence = bundle.getCharSequence(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_ENTRY_GROUP_ID_PREFIX + i);
|
|
boolean z = bundle.getBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_IS_DEFAULT_ICON_PREFERRED_AS_SINGLE_PROV_PREFIX + i, false);
|
|
CharSequence charSequence2 = bundle.getCharSequence(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_AFFILIATED_DOMAIN_PREFIX + i);
|
|
Parcelable parcelable = bundle.getParcelable(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_PENDING_INTENT_PREFIX + i);
|
|
Intrinsics.checkNotNull(parcelable);
|
|
PendingIntent pendingIntent = (PendingIntent) parcelable;
|
|
boolean z2 = bundle.getBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_IS_AUTO_SELECT_ALLOWED_PREFIX + i, false);
|
|
boolean z3 = bundle.getBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_IS_AUTO_SELECT_ALLOWED_FROM_OPTION_PREFIX + i, false);
|
|
boolean z4 = bundle.getBoolean(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_HAS_DEFAULT_ICON_PREFIX + i, false);
|
|
CharSequence charSequence3 = bundle.getCharSequence(CredentialEntry.EXTRA_CREDENTIAL_TITLE_PREFIX + i);
|
|
Intrinsics.checkNotNull(charSequence3);
|
|
CharSequence charSequence4 = bundle.getCharSequence(CredentialEntry.EXTRA_CREDENTIAL_TYPE_DISPLAY_NAME_PREFIX + i);
|
|
Intrinsics.checkNotNull(charSequence4);
|
|
Parcelable parcelable2 = bundle.getParcelable(CredentialEntry.EXTRA_CREDENTIAL_TYPE_ICON_PREFIX + i);
|
|
Intrinsics.checkNotNull(parcelable2);
|
|
Icon icon = (Icon) parcelable2;
|
|
return new PasswordCredentialEntry(charSequence3, bundle.getCharSequence(CredentialEntry.EXTRA_CREDENTIAL_SUBTITLE_PREFIX + i), charSequence4, pendingIntent, (Instant) bundle.getSerializable(CredentialEntry.EXTRA_CREDENTIAL_ENTRY_LAST_USED_TIME_PREFIX + i), icon, z2, BeginGetPasswordOption.Companion.createFrom$credentials_release(bundle2, string), z, charSequence, charSequence2, null, z3, true, z4, 2048, null);
|
|
} catch (Exception unused) {
|
|
return null;
|
|
}
|
|
}
|
|
}
|
|
|
|
public static final class Builder {
|
|
private CharSequence affiliatedDomain;
|
|
private boolean autoSelectAllowed;
|
|
private final BeginGetPasswordOption beginGetPasswordOption;
|
|
private BiometricPromptData biometricPromptData;
|
|
private final Context context;
|
|
private CharSequence displayName;
|
|
private Icon icon;
|
|
private boolean isDefaultIconPreferredAsSingleProvider;
|
|
private Instant lastUsedTime;
|
|
private final PendingIntent pendingIntent;
|
|
private final CharSequence username;
|
|
|
|
public final Builder setAffiliatedDomain(CharSequence charSequence) {
|
|
this.affiliatedDomain = charSequence;
|
|
return this;
|
|
}
|
|
|
|
public final Builder setAutoSelectAllowed(boolean z) {
|
|
this.autoSelectAllowed = z;
|
|
return this;
|
|
}
|
|
|
|
@RequiresApi(35)
|
|
public final Builder setBiometricPromptData(BiometricPromptData biometricPromptData) {
|
|
this.biometricPromptData = biometricPromptData;
|
|
return this;
|
|
}
|
|
|
|
public final Builder setDefaultIconPreferredAsSingleProvider(boolean z) {
|
|
this.isDefaultIconPreferredAsSingleProvider = z;
|
|
return this;
|
|
}
|
|
|
|
public final Builder setDisplayName(CharSequence charSequence) {
|
|
this.displayName = charSequence;
|
|
return this;
|
|
}
|
|
|
|
public final Builder setIcon(Icon icon) {
|
|
Intrinsics.checkNotNullParameter(icon, "icon");
|
|
this.icon = icon;
|
|
return this;
|
|
}
|
|
|
|
public final Builder setLastUsedTime(Instant instant) {
|
|
this.lastUsedTime = instant;
|
|
return this;
|
|
}
|
|
|
|
public Builder(Context context, CharSequence username, PendingIntent pendingIntent, BeginGetPasswordOption beginGetPasswordOption) {
|
|
Intrinsics.checkNotNullParameter(context, "context");
|
|
Intrinsics.checkNotNullParameter(username, "username");
|
|
Intrinsics.checkNotNullParameter(pendingIntent, "pendingIntent");
|
|
Intrinsics.checkNotNullParameter(beginGetPasswordOption, "beginGetPasswordOption");
|
|
this.context = context;
|
|
this.username = username;
|
|
this.pendingIntent = pendingIntent;
|
|
this.beginGetPasswordOption = beginGetPasswordOption;
|
|
}
|
|
|
|
public final PasswordCredentialEntry build() {
|
|
if (this.icon == null) {
|
|
this.icon = Icon.createWithResource(this.context, R.drawable.ic_password);
|
|
}
|
|
String string = this.context.getString(R.string.android_credentials_TYPE_PASSWORD_CREDENTIAL);
|
|
Intrinsics.checkNotNullExpressionValue(string, "context.getString(R.stri…TYPE_PASSWORD_CREDENTIAL)");
|
|
CharSequence charSequence = this.username;
|
|
CharSequence charSequence2 = this.displayName;
|
|
PendingIntent pendingIntent = this.pendingIntent;
|
|
Instant instant = this.lastUsedTime;
|
|
Icon icon = this.icon;
|
|
Intrinsics.checkNotNull(icon);
|
|
return new PasswordCredentialEntry(charSequence, charSequence2, string, pendingIntent, instant, icon, this.autoSelectAllowed, this.beginGetPasswordOption, this.isDefaultIconPreferredAsSingleProvider, null, this.affiliatedDomain, this.biometricPromptData, false, false, false, 29184, null);
|
|
}
|
|
}
|
|
}
|