Table of Contents

LifetimeExtensions Class

public static class LifetimeExtensions

Lifetime extension methods. Use DebuggerAction to extend debugging functionality.

Inheritance
LifetimeExtensions

Fields

DebuggerAction

Arguments: (obj, token, ticket, ownerOrNull)

Invoked when object bound to token or lifetime owner.

Methods

DestroyUnityObjectWith(Object, MonoBehaviour)
DestroyUnityObjectWith(Object, LifecycleBehaviour)
DestroyUnityObjectWith(Object, SceneLifetime)
DestroyUnityObjectWith(Object, CancellationToken)
DestroyWith(GameObject, MonoBehaviour)

Bind GameObject lifetime to MonoBehaviour.

DestroyWith(GameObject, LifecycleBehaviour)

Bind GameObject lifetime to lifecycle owner.

DestroyWith(GameObject, SceneLifetime)

Bind GameObject lifetime to unity scene.

DestroyWith(GameObject, CancellationToken)

Bind GameObject lifetime to cancellation token.

DestroyWith(IDisposable, MonoBehaviour)

Bind disposable lifetime to MonoBehaviour.

DestroyWith(IDisposable, LifecycleBehaviour)

Bind disposable lifetime to lifecycle owner.

DestroyWith(IDisposable, SceneLifetime)

Bind disposable lifetime to unity scene.

DestroyWith(IDisposable, CancellationToken)

Bind disposable lifetime to cancellation token.

DestroyWith(Transform, MonoBehaviour)
DestroyWith(Transform, LifecycleBehaviour)
DestroyWith(Transform, SceneLifetime)
DestroyWith(Transform, CancellationToken)