LifecycleStateObserverLifecycleObserverpublic interface ILifecycleObserver
ILifecycleObserver. The child classes that implement this interface provide related
methods.
You can call the Lifecycle#addObserver(ILifecycleObserver) method to add LifecycleObserver
objects to the observer list. After that, the objects will be notified if the lifecycle state of an
Ability or AbilitySlice changes.
Instead of implementing ILifecycleObserver, you can only use LifecycleObserver or
LifecycleStateObserver to observe lifecycle changes of an Ability or AbilitySlice.
LifecycleObserver,
LifecycleStateObserverSystemCapability.Aafwk#ABILITY