Skip to content

}},System.Func{ReactiveUI.Binding.Reactive.IInteractionContext{--2,--3},System.Threading.Tasks.Task})} }},System.Func{ReactiveUI.Binding.Reactive.IInteractionContext{--2,--3},System.IObservable{--4}})}

ReactiveUIBindingExtensions.BindInteractionUnsafe(TView, TViewModel?, Expression>>, Func, Task>) method

Defined in

Type: ReactiveUIBindingExtensions Namespace: ReactiveUI.Binding.Reactive Assembly: ReactiveUI.Binding.Reactive.dll

Applies to

net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-tvos18.0, net9.0-maccatalyst18.0, net9.0-ios18.0, net9.0-macos15.0, net9.0-desktop1.0, net8.0, net8.0-macos14.5, net8.0-ios18.0, net8.0-maccatalyst18.0, net8.0-macos15.0, net8.0-tvos18.0, net8.0-ios17.5, net8.0-maccatalyst17.5, netstandard2.1, net481, net462, net471

Overloads

  • 1. public static IDisposable BindInteractionUnsafe<TViewModel, TView, TInput, TOutput>(this TView view, TViewModel? viewModel, Expression<Func<TViewModel, IInteraction<TInput, TOutput>>> propertyName, Func<IInteractionContext<TInput, TOutput>, Task> handler) where TViewModel : class where TView : class, IViewFor
  • 2. public static IDisposable BindInteractionUnsafe<TViewModel, TView, TInput, TOutput, TDontCare>(this TView view, TViewModel? viewModel, Expression<Func<TViewModel, IInteraction<TInput, TOutput>>> propertyName, Func<IInteractionContext<TInput, TOutput>, IObservable<TDontCare>> handler) where TViewModel : class where TView : class, IViewFor

1. Overload

Attributes: [RequiresUnreferencedCode("Evaluates expression-based member chains via reflection; members may be trimmed.")]

public static IDisposable BindInteractionUnsafe<TViewModel, TView, TInput, TOutput>(this TView view, TViewModel? viewModel, Expression<Func<TViewModel, IInteraction<TInput, TOutput>>> propertyName, Func<IInteractionContext<TInput, TOutput>, Task> handler) where TViewModel : class where TView : class, IViewFor

View source

Summary: Binds a task-based handler to an interaction exposed by the view model.

Type parameters

NameDescription
TViewModelThe type of the view model.
TViewThe type of the view.
TInputThe type of the interaction's input.
TOutputThe type of the interaction's output.

Parameters

NameTypeDescription
viewTViewThe view that provides the handler.
viewModelTViewModel?The view model that exposes the interaction.
propertyNameExpression>>An expression that selects the interaction property on the view model.
handlerFunc, Task>A task-based handler for the interaction.

Returns: IDisposable -- A disposable that, when disposed, disconnects the binding.

Remarks

Resolves the property chain by reflection, for an expression the generator could not read.

2. Overload

Attributes: [RequiresUnreferencedCode("Evaluates expression-based member chains via reflection; members may be trimmed.")]

public static IDisposable BindInteractionUnsafe<TViewModel, TView, TInput, TOutput, TDontCare>(this TView view, TViewModel? viewModel, Expression<Func<TViewModel, IInteraction<TInput, TOutput>>> propertyName, Func<IInteractionContext<TInput, TOutput>, IObservable<TDontCare>> handler) where TViewModel : class where TView : class, IViewFor

View source

Summary: Binds an observable-based handler to an interaction exposed by the view model.

Type parameters

NameDescription
TViewModelThe type of the view model.
TViewThe type of the view.
TInputThe type of the interaction's input.
TOutputThe type of the interaction's output.
TDontCareThe signal type of the observable handler.

Parameters

NameTypeDescription
viewTViewThe view that provides the handler.
viewModelTViewModel?The view model that exposes the interaction.
propertyNameExpression>>An expression that selects the interaction property on the view model.
handlerFunc, IObservable>An observable-based handler for the interaction.

Returns: IDisposable -- A disposable that, when disposed, disconnects the binding.

Remarks

Resolves the property chain by reflection, for an expression the generator could not read.