Share via


BindingSource.CanAcceptDataFrom(BindingSource) Method

Definition

Gets a value indicating whether or not the BindingSource can accept data from bindingSource.

public:
 virtual bool CanAcceptDataFrom(Microsoft::AspNetCore::Mvc::ModelBinding::BindingSource ^ bindingSource);
public virtual bool CanAcceptDataFrom (Microsoft.AspNetCore.Mvc.ModelBinding.BindingSource bindingSource);
abstract member CanAcceptDataFrom : Microsoft.AspNetCore.Mvc.ModelBinding.BindingSource -> bool
override this.CanAcceptDataFrom : Microsoft.AspNetCore.Mvc.ModelBinding.BindingSource -> bool
Public Overridable Function CanAcceptDataFrom (bindingSource As BindingSource) As Boolean

Parameters

bindingSource
BindingSource

The BindingSource to consider as input.

Returns

True if the source is compatible, otherwise false.

Remarks

When using this method, it is expected that the left-hand-side is metadata specified on a property or parameter for model binding, and the right hand side is a source of data used by a model binder or value provider.

This distinction is important as the left-hand-side may be a composite, but the right may not.

Applies to