DictionaryModelBinderProvider.GetBinder 方法

定义

返回字典的模型联编程序。

public:
 override System::Web::ModelBinding::IModelBinder ^ GetBinder(System::Web::ModelBinding::ModelBindingExecutionContext ^ modelBindingExecutionContext, System::Web::ModelBinding::ModelBindingContext ^ bindingContext);
public override System.Web.ModelBinding.IModelBinder GetBinder (System.Web.ModelBinding.ModelBindingExecutionContext modelBindingExecutionContext, System.Web.ModelBinding.ModelBindingContext bindingContext);
override this.GetBinder : System.Web.ModelBinding.ModelBindingExecutionContext * System.Web.ModelBinding.ModelBindingContext -> System.Web.ModelBinding.IModelBinder
Public Overrides Function GetBinder (modelBindingExecutionContext As ModelBindingExecutionContext, bindingContext As ModelBindingContext) As IModelBinder

参数

modelBindingExecutionContext
ModelBindingExecutionContext

该执行上下文。

bindingContext
ModelBindingContext

绑定上下文。

返回

IModelBinder

如果尝试获取模型绑定器不成功,则为模型绑定器,或 null

注解

如果值提供程序的 方法返回 ,则尝试获取模型联编程序 ContainsPrefix 将失败 false

适用于