Skip to content

ILifecycleObservable Methods

Observable lifecycle. Each stage of the lifecycle is observable. All observers will be notified when the stage is reached when starting, and stopping. Stages are started in ascending order, and stopped in descending order.

Subscribe(string, int, ILifecycleObserver)

abstract
public abstract IDisposable Subscribe(string observerName, int stage, ILifecycleObserver observer)
Subscribe for notification when a stage is reached while starting or stopping.

Parameters

observerNamestring
The name of the observer, for reporting purposes.
stageint
The stage of to subscribe to.
observerILifecycleObserver
The observer.

Returns

A disposable that can be disposed of to unsubscribe.