Table of Contents

ThrowIfNull Method

ThrowIfNull<T>(T?, string?, Exception?) Deprecated

[Obsolete("use `.Nullable() ?? throw new...` instead")]
public static T ThrowIfNull<T>(this T? self, string? message = null, Exception? innerException = null) where T : UnityEngine.Object

Parameters

self T
message string
innerException Exception

Returns

T

Type Parameters

T

Exceptions

NullReferenceException