Class RetainedLifecycleImpl
java.lang.Object
dagger.hilt.android.internal.lifecycle.RetainedLifecycleImpl
- All Implemented Interfaces:
ActivityRetainedLifecycle
,RetainedLifecycle
,ViewModelLifecycle
public final class RetainedLifecycleImpl
extends Object
implements ActivityRetainedLifecycle, ViewModelLifecycle
Internal implementation. Do not use.
-
Nested Class Summary
Nested classes/interfaces inherited from interface dagger.hilt.android.ActivityRetainedLifecycle
ActivityRetainedLifecycle.OnClearedListener
Nested classes/interfaces inherited from interface dagger.hilt.android.lifecycle.RetainedLifecycle
RetainedLifecycle.OnClearedListener
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds a newRetainedLifecycle.OnClearedListener
for receiving a callback when the lifecycle is cleared.void
void
Removes aRetainedLifecycle.OnClearedListener
previously added viaRetainedLifecycle.addOnClearedListener(OnClearedListener)
.
-
Constructor Details
-
RetainedLifecycleImpl
public RetainedLifecycleImpl()
-
-
Method Details
-
addOnClearedListener
Description copied from interface:RetainedLifecycle
Adds a newRetainedLifecycle.OnClearedListener
for receiving a callback when the lifecycle is cleared.- Specified by:
addOnClearedListener
in interfaceRetainedLifecycle
- Parameters:
listener
- The listener that should be added.
-
removeOnClearedListener
Description copied from interface:RetainedLifecycle
Removes aRetainedLifecycle.OnClearedListener
previously added viaRetainedLifecycle.addOnClearedListener(OnClearedListener)
.- Specified by:
removeOnClearedListener
in interfaceRetainedLifecycle
- Parameters:
listener
- The listener that should be removed.
-
dispatchOnCleared
public void dispatchOnCleared()
-