mirror of
https://github.com/Pinball3D/Rabbit-R1.git
synced 2025-01-09 13:43:22 +00:00
717 lines
22 KiB
Smali
717 lines
22 KiB
Smali
.class public final Landroidx/savedstate/SavedStateRegistry;
|
|
.super Ljava/lang/Object;
|
|
.source "SavedStateRegistry.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Landroidx/savedstate/SavedStateRegistry$AutoRecreated;,
|
|
Landroidx/savedstate/SavedStateRegistry$Companion;,
|
|
Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;
|
|
}
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/SourceDebugExtension;
|
|
value = "SMAP\nSavedStateRegistry.kt\nKotlin\n*S Kotlin\n*F\n+ 1 SavedStateRegistry.kt\nandroidx/savedstate/SavedStateRegistry\n+ 2 fake.kt\nkotlin/jvm/internal/FakeKt\n*L\n1#1,272:1\n1#2:273\n*E\n"
|
|
.end annotation
|
|
|
|
.annotation runtime Lkotlin/Metadata;
|
|
d1 = {
|
|
"\u0000J\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\u0008\u0002\n\u0002\u0010\u000b\n\u0000\n\u0002\u0018\u0002\n\u0002\u0010\u000e\n\u0002\u0018\u0002\n\u0002\u0008\u0008\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\u0008\u0004\n\u0002\u0010\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\u0008\n\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0008\u0005\u0008\u0007\u0018\u0000 )2\u00020\u0001:\u0003()*B\u0007\u0008\u0000\u00a2\u0006\u0002\u0010\u0002J\u0012\u0010\u0014\u001a\u0004\u0018\u00010\u00132\u0006\u0010\u0015\u001a\u00020\u0007H\u0007J\u0010\u0010\u0016\u001a\u0004\u0018\u00010\u00082\u0006\u0010\u0015\u001a\u00020\u0007J\u0015\u0010\u0017\u001a\u00020\u00182\u0006\u0010\u0019\u001a\u00020\u001aH\u0001\u00a2\u0006\u0002\u0008\u001bJ\u0017\u0010\u001c\u001a\u00020\u00182\u0008\u0010\u001d\u001a\u0004\u0018\u00010\u0013H\u0001\u00a2\u0006\u0002\u0008\u001eJ\u0010\u0010\u001f\u001a\u00020\u00182\u0006\u0010 \u001a\u00020\u0013H\u0007J\u0018\u0010!\u001a\u00020\u00182\u0006\u0010\u0015\u001a\u00020\u00072\u0006\u0010\"\u001a\u00020\u0008H\u0007J\u0018\u0010#\u001a\u00020\u00182\u000e\u0010$\u001a\n\u0012\u0006\u0008\u0001\u0012\u00020&0%H\u0007J\u0010\u0010\'\u001a\u00020\u00182\u0006\u0010\u0015\u001a\u00020\u0007H\u0007R\u000e\u0010\u0003\u001a\u00020\u0004X\u0082\u000e\u00a2\u0006\u0002\n\u0000R\u001a\u0010\u0005\u001a\u000e\u0012\u0004\u0012\u00020\u0007\u0012\u0004\u0012\u00020\u00080\u0006X\u0082\u0004\u00a2\u0006\u0002\n\u0000R\u001a\u0010\t\u001a\u00020\u0004X\u0080\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\n\u0010\u000b\"\u0004\u0008\u000c\u0010\rR \u0010\u000f\u001a\u00020\u00042\u0006\u0010\u000e\u001a\u00020\u00048G@BX\u0086\u000e\u00a2\u0006\u0008\n\u0000\u001a\u0004\u0008\u000f\u0010\u000bR\u0010\u0010\u0010\u001a\u0004\u0018\u00010\u0011X\u0082\u000e\u00a2\u0006\u0002\n\u0000R\u0010\u0010\u0012\u001a\u0004\u0018\u00010\u0013X\u0082\u000e\u00a2\u0006\u0002\n\u0000\u00a8\u0006+"
|
|
}
|
|
d2 = {
|
|
"Landroidx/savedstate/SavedStateRegistry;",
|
|
"",
|
|
"()V",
|
|
"attached",
|
|
"",
|
|
"components",
|
|
"Landroidx/arch/core/internal/SafeIterableMap;",
|
|
"",
|
|
"Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;",
|
|
"isAllowingSavingState",
|
|
"isAllowingSavingState$savedstate_release",
|
|
"()Z",
|
|
"setAllowingSavingState$savedstate_release",
|
|
"(Z)V",
|
|
"<set-?>",
|
|
"isRestored",
|
|
"recreatorProvider",
|
|
"Landroidx/savedstate/Recreator$SavedStateProvider;",
|
|
"restoredState",
|
|
"Landroid/os/Bundle;",
|
|
"consumeRestoredStateForKey",
|
|
"key",
|
|
"getSavedStateProvider",
|
|
"performAttach",
|
|
"",
|
|
"lifecycle",
|
|
"Landroidx/lifecycle/Lifecycle;",
|
|
"performAttach$savedstate_release",
|
|
"performRestore",
|
|
"savedState",
|
|
"performRestore$savedstate_release",
|
|
"performSave",
|
|
"outBundle",
|
|
"registerSavedStateProvider",
|
|
"provider",
|
|
"runOnNextRecreation",
|
|
"clazz",
|
|
"Ljava/lang/Class;",
|
|
"Landroidx/savedstate/SavedStateRegistry$AutoRecreated;",
|
|
"unregisterSavedStateProvider",
|
|
"AutoRecreated",
|
|
"Companion",
|
|
"SavedStateProvider",
|
|
"savedstate_release"
|
|
}
|
|
k = 0x1
|
|
mv = {
|
|
0x1,
|
|
0x8,
|
|
0x0
|
|
}
|
|
xi = 0x30
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field private static final Companion:Landroidx/savedstate/SavedStateRegistry$Companion;
|
|
|
|
.field private static final SAVED_COMPONENTS_KEY:Ljava/lang/String; = "androidx.lifecycle.BundlableSavedStateRegistry.key"
|
|
.annotation runtime Ljava/lang/Deprecated;
|
|
.end annotation
|
|
.end field
|
|
|
|
|
|
# instance fields
|
|
.field private attached:Z
|
|
|
|
.field private final components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Landroidx/arch/core/internal/SafeIterableMap<",
|
|
"Ljava/lang/String;",
|
|
"Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
.field private isAllowingSavingState:Z
|
|
|
|
.field private isRestored:Z
|
|
|
|
.field private recreatorProvider:Landroidx/savedstate/Recreator$SavedStateProvider;
|
|
|
|
.field private restoredState:Landroid/os/Bundle;
|
|
|
|
|
|
# direct methods
|
|
.method public static synthetic $r8$lambda$AUDDdpkzZrJMhBj0r-_9pI-j6hA(Landroidx/savedstate/SavedStateRegistry;Landroidx/lifecycle/LifecycleOwner;Landroidx/lifecycle/Lifecycle$Event;)V
|
|
.locals 0
|
|
|
|
invoke-static {p0, p1, p2}, Landroidx/savedstate/SavedStateRegistry;->performAttach$lambda$4(Landroidx/savedstate/SavedStateRegistry;Landroidx/lifecycle/LifecycleOwner;Landroidx/lifecycle/Lifecycle$Event;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method static constructor <clinit>()V
|
|
.locals 2
|
|
|
|
new-instance v0, Landroidx/savedstate/SavedStateRegistry$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Landroidx/savedstate/SavedStateRegistry$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sput-object v0, Landroidx/savedstate/SavedStateRegistry;->Companion:Landroidx/savedstate/SavedStateRegistry$Companion;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 1
|
|
|
|
.line 32
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
.line 34
|
|
new-instance v0, Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
invoke-direct {v0}, Landroidx/arch/core/internal/SafeIterableMap;-><init>()V
|
|
|
|
iput-object v0, p0, Landroidx/savedstate/SavedStateRegistry;->components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
const/4 v0, 0x1
|
|
|
|
iput-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private static final performAttach$lambda$4(Landroidx/savedstate/SavedStateRegistry;Landroidx/lifecycle/LifecycleOwner;Landroidx/lifecycle/Lifecycle$Event;)V
|
|
.locals 1
|
|
|
|
const-string v0, "this$0"
|
|
|
|
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "<anonymous parameter 0>"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string p1, "event"
|
|
|
|
invoke-static {p2, p1}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
.line 202
|
|
sget-object p1, Landroidx/lifecycle/Lifecycle$Event;->ON_START:Landroidx/lifecycle/Lifecycle$Event;
|
|
|
|
if-ne p2, p1, :cond_0
|
|
|
|
const/4 p1, 0x1
|
|
|
|
.line 203
|
|
iput-boolean p1, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
goto :goto_0
|
|
|
|
.line 204
|
|
:cond_0
|
|
sget-object p1, Landroidx/lifecycle/Lifecycle$Event;->ON_STOP:Landroidx/lifecycle/Lifecycle$Event;
|
|
|
|
if-ne p2, p1, :cond_1
|
|
|
|
const/4 p1, 0x0
|
|
|
|
.line 205
|
|
iput-boolean p1, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
:cond_1
|
|
:goto_0
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final consumeRestoredStateForKey(Ljava/lang/String;)Landroid/os/Bundle;
|
|
.locals 3
|
|
|
|
const-string v0, "key"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->isRestored:Z
|
|
|
|
if-eqz v0, :cond_4
|
|
|
|
iget-object v0, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-eqz v0, :cond_3
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
.line 77
|
|
invoke-virtual {v0, p1}, Landroid/os/Bundle;->getBundle(Ljava/lang/String;)Landroid/os/Bundle;
|
|
|
|
move-result-object v0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
move-object v0, v1
|
|
|
|
:goto_0
|
|
iget-object v2, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
.line 78
|
|
invoke-virtual {v2, p1}, Landroid/os/Bundle;->remove(Ljava/lang/String;)V
|
|
|
|
:cond_1
|
|
iget-object p1, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
.line 79
|
|
invoke-virtual {p1}, Landroid/os/Bundle;->isEmpty()Z
|
|
|
|
move-result p1
|
|
|
|
if-nez p1, :cond_2
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
iput-object v1, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
:goto_1
|
|
return-object v0
|
|
|
|
:cond_3
|
|
return-object v1
|
|
|
|
.line 72
|
|
:cond_4
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "You can consumeRestoredStateForKey only after super.onCreate of corresponding component"
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public final getSavedStateProvider(Ljava/lang/String;)Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;
|
|
.locals 2
|
|
|
|
const-string v0, "key"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-object p0, p0, Landroidx/savedstate/SavedStateRegistry;->components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
.line 128
|
|
invoke-virtual {p0}, Landroidx/arch/core/internal/SafeIterableMap;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object p0
|
|
|
|
:cond_0
|
|
invoke-interface {p0}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
invoke-interface {p0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Ljava/util/Map$Entry;
|
|
|
|
const-string v1, "components"
|
|
|
|
invoke-static {v0, v1}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullExpressionValue(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-interface {v0}, Ljava/util/Map$Entry;->getKey()Ljava/lang/Object;
|
|
|
|
move-result-object v1
|
|
|
|
check-cast v1, Ljava/lang/String;
|
|
|
|
invoke-interface {v0}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;
|
|
|
|
.line 129
|
|
invoke-static {v1, p1}, Lkotlin/jvm/internal/Intrinsics;->areEqual(Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
const/4 v0, 0x0
|
|
|
|
:goto_0
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public final isAllowingSavingState$savedstate_release()Z
|
|
.locals 0
|
|
|
|
iget-boolean p0, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public final isRestored()Z
|
|
.locals 0
|
|
|
|
iget-boolean p0, p0, Landroidx/savedstate/SavedStateRegistry;->isRestored:Z
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public final performAttach$savedstate_release(Landroidx/lifecycle/Lifecycle;)V
|
|
.locals 2
|
|
|
|
const-string v0, "lifecycle"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->attached:Z
|
|
|
|
const/4 v1, 0x1
|
|
|
|
xor-int/2addr v0, v1
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
.line 201
|
|
new-instance v0, Landroidx/savedstate/SavedStateRegistry$$ExternalSyntheticLambda0;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/savedstate/SavedStateRegistry$$ExternalSyntheticLambda0;-><init>(Landroidx/savedstate/SavedStateRegistry;)V
|
|
|
|
check-cast v0, Landroidx/lifecycle/LifecycleObserver;
|
|
|
|
invoke-virtual {p1, v0}, Landroidx/lifecycle/Lifecycle;->addObserver(Landroidx/lifecycle/LifecycleObserver;)V
|
|
|
|
iput-boolean v1, p0, Landroidx/savedstate/SavedStateRegistry;->attached:Z
|
|
|
|
return-void
|
|
|
|
.line 199
|
|
:cond_0
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "SavedStateRegistry was already attached."
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public final performRestore$savedstate_release(Landroid/os/Bundle;)V
|
|
.locals 2
|
|
|
|
iget-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->attached:Z
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
iget-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->isRestored:Z
|
|
|
|
const/4 v1, 0x1
|
|
|
|
xor-int/2addr v0, v1
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
const-string v0, "androidx.lifecycle.BundlableSavedStateRegistry.key"
|
|
|
|
.line 222
|
|
invoke-virtual {p1, v0}, Landroid/os/Bundle;->getBundle(Ljava/lang/String;)Landroid/os/Bundle;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p1, 0x0
|
|
|
|
:goto_0
|
|
iput-object p1, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
iput-boolean v1, p0, Landroidx/savedstate/SavedStateRegistry;->isRestored:Z
|
|
|
|
return-void
|
|
|
|
.line 221
|
|
:cond_1
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "SavedStateRegistry was already restored."
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
|
|
.line 217
|
|
:cond_2
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "You must call performAttach() before calling performRestore(Bundle)."
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public final performSave(Landroid/os/Bundle;)V
|
|
.locals 3
|
|
|
|
const-string v0, "outBundle"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
.line 239
|
|
new-instance v0, Landroid/os/Bundle;
|
|
|
|
invoke-direct {v0}, Landroid/os/Bundle;-><init>()V
|
|
|
|
iget-object v1, p0, Landroidx/savedstate/SavedStateRegistry;->restoredState:Landroid/os/Bundle;
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
.line 241
|
|
invoke-virtual {v0, v1}, Landroid/os/Bundle;->putAll(Landroid/os/Bundle;)V
|
|
|
|
:cond_0
|
|
iget-object p0, p0, Landroidx/savedstate/SavedStateRegistry;->components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
.line 244
|
|
invoke-virtual {p0}, Landroidx/arch/core/internal/SafeIterableMap;->iteratorWithAdditions()Landroidx/arch/core/internal/SafeIterableMap$IteratorWithAdditions;
|
|
|
|
move-result-object p0
|
|
|
|
const-string v1, "this.components.iteratorWithAdditions()"
|
|
|
|
invoke-static {p0, v1}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullExpressionValue(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
check-cast p0, Ljava/util/Iterator;
|
|
|
|
.line 245
|
|
:goto_0
|
|
invoke-interface {p0}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_1
|
|
|
|
.line 246
|
|
invoke-interface {p0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v1
|
|
|
|
check-cast v1, Ljava/util/Map$Entry;
|
|
|
|
invoke-interface {v1}, Ljava/util/Map$Entry;->getKey()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Ljava/lang/String;
|
|
|
|
invoke-interface {v1}, Ljava/util/Map$Entry;->getValue()Ljava/lang/Object;
|
|
|
|
move-result-object v1
|
|
|
|
check-cast v1, Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;
|
|
|
|
.line 247
|
|
invoke-interface {v1}, Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;->saveState()Landroid/os/Bundle;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, v2, v1}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V
|
|
|
|
goto :goto_0
|
|
|
|
.line 249
|
|
:cond_1
|
|
invoke-virtual {v0}, Landroid/os/Bundle;->isEmpty()Z
|
|
|
|
move-result p0
|
|
|
|
if-nez p0, :cond_2
|
|
|
|
const-string p0, "androidx.lifecycle.BundlableSavedStateRegistry.key"
|
|
|
|
.line 250
|
|
invoke-virtual {p1, p0, v0}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V
|
|
|
|
:cond_2
|
|
return-void
|
|
.end method
|
|
|
|
.method public final registerSavedStateProvider(Ljava/lang/String;Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;)V
|
|
.locals 1
|
|
|
|
const-string v0, "key"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "provider"
|
|
|
|
invoke-static {p2, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-object p0, p0, Landroidx/savedstate/SavedStateRegistry;->components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
.line 109
|
|
invoke-virtual {p0, p1, p2}, Landroidx/arch/core/internal/SafeIterableMap;->putIfAbsent(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object p0
|
|
|
|
check-cast p0, Landroidx/savedstate/SavedStateRegistry$SavedStateProvider;
|
|
|
|
if-nez p0, :cond_0
|
|
|
|
return-void
|
|
|
|
.line 110
|
|
:cond_0
|
|
new-instance p0, Ljava/lang/IllegalArgumentException;
|
|
|
|
const-string p1, "SavedStateProvider with the given key is already registered"
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public final runOnNextRecreation(Ljava/lang/Class;)V
|
|
.locals 3
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/lang/Class<",
|
|
"+",
|
|
"Landroidx/savedstate/SavedStateRegistry$AutoRecreated;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
const-string v0, "clazz"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-boolean v0, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
iget-object v0, p0, Landroidx/savedstate/SavedStateRegistry;->recreatorProvider:Landroidx/savedstate/Recreator$SavedStateProvider;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 181
|
|
new-instance v0, Landroidx/savedstate/Recreator$SavedStateProvider;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/savedstate/Recreator$SavedStateProvider;-><init>(Landroidx/savedstate/SavedStateRegistry;)V
|
|
|
|
:cond_0
|
|
iput-object v0, p0, Landroidx/savedstate/SavedStateRegistry;->recreatorProvider:Landroidx/savedstate/Recreator$SavedStateProvider;
|
|
|
|
const/4 v0, 0x0
|
|
|
|
:try_start_0
|
|
new-array v0, v0, [Ljava/lang/Class;
|
|
|
|
.line 183
|
|
invoke-virtual {p1, v0}, Ljava/lang/Class;->getDeclaredConstructor([Ljava/lang/Class;)Ljava/lang/reflect/Constructor;
|
|
:try_end_0
|
|
.catch Ljava/lang/NoSuchMethodException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
iget-object p0, p0, Landroidx/savedstate/SavedStateRegistry;->recreatorProvider:Landroidx/savedstate/Recreator$SavedStateProvider;
|
|
|
|
if-eqz p0, :cond_1
|
|
|
|
.line 190
|
|
invoke-virtual {p1}, Ljava/lang/Class;->getName()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
const-string v0, "clazz.name"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullExpressionValue(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p0, p1}, Landroidx/savedstate/Recreator$SavedStateProvider;->add(Ljava/lang/String;)V
|
|
|
|
:cond_1
|
|
return-void
|
|
|
|
:catch_0
|
|
move-exception p0
|
|
|
|
.line 185
|
|
new-instance v0, Ljava/lang/IllegalArgumentException;
|
|
|
|
.line 186
|
|
new-instance v1, Ljava/lang/StringBuilder;
|
|
|
|
const-string v2, "Class "
|
|
|
|
invoke-direct {v1, v2}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object p1
|
|
|
|
const-string v1, " must have default constructor in order to be automatically recreated"
|
|
|
|
invoke-virtual {p1, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
.line 187
|
|
check-cast p0, Ljava/lang/Throwable;
|
|
|
|
.line 185
|
|
invoke-direct {v0, p1, p0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V
|
|
|
|
throw v0
|
|
|
|
.line 180
|
|
:cond_2
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "Can not perform this action after onSaveInstanceState"
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public final setAllowingSavingState$savedstate_release(Z)V
|
|
.locals 0
|
|
|
|
iput-boolean p1, p0, Landroidx/savedstate/SavedStateRegistry;->isAllowingSavingState:Z
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final unregisterSavedStateProvider(Ljava/lang/String;)V
|
|
.locals 1
|
|
|
|
const-string v0, "key"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget-object p0, p0, Landroidx/savedstate/SavedStateRegistry;->components:Landroidx/arch/core/internal/SafeIterableMap;
|
|
|
|
.line 144
|
|
invoke-virtual {p0, p1}, Landroidx/arch/core/internal/SafeIterableMap;->remove(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
return-void
|
|
.end method
|