,System.String,System.String,System.Int32)}
SubscribeSafeExtensions.SubscribeSafe(IObservable, string?, string?, int) method¶
Defined in
Type: SubscribeSafeExtensions
Namespace: System.Reactive.Linq
Assembly: Sextant.dll
Applies to
net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-browserwasm1.0, net9.0-desktop1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, netstandard2.0, net471
public static IDisposable SubscribeSafe<T>(this IObservable<T> observable, string? callerMemberName = null, string? callerFilePath = null, int callerLineNumber = 0)
Summary: Subscribes to an Observable and provides default debugging in the case of an exception. It will provide the caller information as part of the logging.
Type parameters
| Name | Description |
|---|---|
T | The type of item signaled as part of the observable. |
Parameters
| Name | Type | Description |
|---|---|---|
observable | IObservable | The observable to subscribe to. |
callerMemberName = null | string? | The name of the caller member. |
callerFilePath = null | string? | The file path of the caller member. |
callerLineNumber = 0 | int | The line number of the caller member. |
Returns: IDisposable -- A disposable which when disposed will unsubscribe from the observable.