1// Signature format: 4.0 2package androidx.lifecycle { 3 4 public interface DefaultLifecycleObserver extends androidx.lifecycle.LifecycleObserver { 5 method public default void onCreate(androidx.lifecycle.LifecycleOwner owner); 6 method public default void onDestroy(androidx.lifecycle.LifecycleOwner owner); 7 method public default void onPause(androidx.lifecycle.LifecycleOwner owner); 8 method public default void onResume(androidx.lifecycle.LifecycleOwner owner); 9 method public default void onStart(androidx.lifecycle.LifecycleOwner owner); 10 method public default void onStop(androidx.lifecycle.LifecycleOwner owner); 11 } 12 13 @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public interface GeneratedAdapter { 14 method public void callMethods(androidx.lifecycle.LifecycleOwner source, androidx.lifecycle.Lifecycle.Event event, boolean onAny, androidx.lifecycle.MethodCallsLogger? logger); 15 } 16 17 @Deprecated @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public interface GenericLifecycleObserver extends androidx.lifecycle.LifecycleEventObserver { 18 } 19 20 public abstract class Lifecycle { 21 ctor public Lifecycle(); 22 method @MainThread public abstract void addObserver(androidx.lifecycle.LifecycleObserver observer); 23 method @MainThread public abstract androidx.lifecycle.Lifecycle.State getCurrentState(); 24 method @MainThread public abstract void removeObserver(androidx.lifecycle.LifecycleObserver observer); 25 property @MainThread public abstract androidx.lifecycle.Lifecycle.State currentState; 26 } 27 28 public enum Lifecycle.Event { 29 method public static final androidx.lifecycle.Lifecycle.Event? downFrom(androidx.lifecycle.Lifecycle.State state); 30 method public static final androidx.lifecycle.Lifecycle.Event? downTo(androidx.lifecycle.Lifecycle.State state); 31 method public final androidx.lifecycle.Lifecycle.State getTargetState(); 32 method public static final androidx.lifecycle.Lifecycle.Event? upFrom(androidx.lifecycle.Lifecycle.State state); 33 method public static final androidx.lifecycle.Lifecycle.Event? upTo(androidx.lifecycle.Lifecycle.State state); 34 property public final androidx.lifecycle.Lifecycle.State targetState; 35 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_ANY; 36 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_CREATE; 37 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_DESTROY; 38 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_PAUSE; 39 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_RESUME; 40 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_START; 41 enum_constant public static final androidx.lifecycle.Lifecycle.Event ON_STOP; 42 field public static final androidx.lifecycle.Lifecycle.Event.Companion Companion; 43 } 44 45 public static final class Lifecycle.Event.Companion { 46 method public androidx.lifecycle.Lifecycle.Event? downFrom(androidx.lifecycle.Lifecycle.State state); 47 method public androidx.lifecycle.Lifecycle.Event? downTo(androidx.lifecycle.Lifecycle.State state); 48 method public androidx.lifecycle.Lifecycle.Event? upFrom(androidx.lifecycle.Lifecycle.State state); 49 method public androidx.lifecycle.Lifecycle.Event? upTo(androidx.lifecycle.Lifecycle.State state); 50 } 51 52 public enum Lifecycle.State { 53 method public final boolean isAtLeast(androidx.lifecycle.Lifecycle.State state); 54 enum_constant public static final androidx.lifecycle.Lifecycle.State CREATED; 55 enum_constant public static final androidx.lifecycle.Lifecycle.State DESTROYED; 56 enum_constant public static final androidx.lifecycle.Lifecycle.State INITIALIZED; 57 enum_constant public static final androidx.lifecycle.Lifecycle.State RESUMED; 58 enum_constant public static final androidx.lifecycle.Lifecycle.State STARTED; 59 } 60 61 public abstract class LifecycleCoroutineScope implements kotlinx.coroutines.CoroutineScope { 62 method @Deprecated public final kotlinx.coroutines.Job launchWhenCreated(kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super kotlin.Unit>,?> block); 63 method @Deprecated public final kotlinx.coroutines.Job launchWhenResumed(kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super kotlin.Unit>,?> block); 64 method @Deprecated public final kotlinx.coroutines.Job launchWhenStarted(kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super kotlin.Unit>,?> block); 65 } 66 67 public fun interface LifecycleEventObserver extends androidx.lifecycle.LifecycleObserver { 68 method public void onStateChanged(androidx.lifecycle.LifecycleOwner source, androidx.lifecycle.Lifecycle.Event event); 69 } 70 71 public final class LifecycleKt { 72 method public static androidx.lifecycle.LifecycleCoroutineScope getCoroutineScope(androidx.lifecycle.Lifecycle); 73 } 74 75 public interface LifecycleObserver { 76 } 77 78 public interface LifecycleOwner { 79 method public androidx.lifecycle.Lifecycle getLifecycle(); 80 property public abstract androidx.lifecycle.Lifecycle lifecycle; 81 } 82 83 public final class LifecycleOwnerKt { 84 method public static androidx.lifecycle.LifecycleCoroutineScope getLifecycleScope(androidx.lifecycle.LifecycleOwner); 85 } 86 87 @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public final class Lifecycling { 88 method public static String getAdapterName(String className); 89 method public static androidx.lifecycle.LifecycleEventObserver lifecycleEventObserver(Object object); 90 } 91 92 @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public class MethodCallsLogger { 93 ctor public MethodCallsLogger(); 94 method @RestrictTo(androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP_PREFIX) public boolean approveCall(String name, int type); 95 } 96 97 @Deprecated @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.RUNTIME) @java.lang.annotation.Target(java.lang.annotation.ElementType.METHOD) public @interface OnLifecycleEvent { 98 method @Deprecated public abstract androidx.lifecycle.Lifecycle.Event value(); 99 } 100 101 public final class PausingDispatcherKt { 102 method @Deprecated public static suspend <T> Object? whenCreated(androidx.lifecycle.Lifecycle, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 103 method @Deprecated public static suspend <T> Object? whenCreated(androidx.lifecycle.LifecycleOwner, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 104 method @Deprecated public static suspend <T> Object? whenResumed(androidx.lifecycle.Lifecycle, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 105 method @Deprecated public static suspend <T> Object? whenResumed(androidx.lifecycle.LifecycleOwner, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 106 method @Deprecated public static suspend <T> Object? whenStarted(androidx.lifecycle.Lifecycle, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 107 method @Deprecated public static suspend <T> Object? whenStarted(androidx.lifecycle.LifecycleOwner, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 108 method @Deprecated public static suspend <T> Object? whenStateAtLeast(androidx.lifecycle.Lifecycle, androidx.lifecycle.Lifecycle.State minState, kotlin.jvm.functions.Function2<? super kotlinx.coroutines.CoroutineScope,? super kotlin.coroutines.Continuation<? super T>,?> block, kotlin.coroutines.Continuation<? super T>); 109 } 110 111} 112 113