ModelBinder<TModel>.BindMemberFromValue Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| BindMemberFromValue<TValue>(Expression<Func<TModel,TValue>>, Symbol) |
Configures a custom binding behavior for the specified property. |
| BindMemberFromValue<TValue>(Expression<Func<TModel,TValue>>, Func<BindingContext,TValue>) |
Configures a custom binding behavior for the specified property. |
BindMemberFromValue<TValue>(Expression<Func<TModel,TValue>>, Symbol)
- Source:
- ModelBinder{T}.cs
Configures a custom binding behavior for the specified property.
public:
generic <typename TValue>
void BindMemberFromValue(System::Linq::Expressions::Expression<Func<TModel, TValue> ^> ^ property, System::CommandLine::Symbol ^ symbol);
public void BindMemberFromValue<TValue>(System.Linq.Expressions.Expression<Func<TModel,TValue>> property, System.CommandLine.Symbol symbol);
override this.BindMemberFromValue : System.Linq.Expressions.Expression<Func<'Model, 'Value>> * System.CommandLine.Symbol -> unit
Public Sub BindMemberFromValue(Of TValue) (property As Expression(Of Func(Of TModel, TValue)), symbol As Symbol)
Type Parameters
- TValue
The type of the value to be bound.
Parameters
- property
- Expression<Func<TModel,TValue>>
An expression specifying the property to bind.
- symbol
- Symbol
Symbol for the value from which the property will be bound.
Applies to
BindMemberFromValue<TValue>(Expression<Func<TModel,TValue>>, Func<BindingContext,TValue>)
- Source:
- ModelBinder{T}.cs
Configures a custom binding behavior for the specified property.
public:
generic <typename TValue>
void BindMemberFromValue(System::Linq::Expressions::Expression<Func<TModel, TValue> ^> ^ property, Func<System::CommandLine::Binding::BindingContext ^, TValue> ^ getValue);
public void BindMemberFromValue<TValue>(System.Linq.Expressions.Expression<Func<TModel,TValue>> property, Func<System.CommandLine.Binding.BindingContext?,TValue> getValue);
override this.BindMemberFromValue : System.Linq.Expressions.Expression<Func<'Model, 'Value>> * Func<System.CommandLine.Binding.BindingContext, 'Value> -> unit
Public Sub BindMemberFromValue(Of TValue) (property As Expression(Of Func(Of TModel, TValue)), getValue As Func(Of BindingContext, TValue))
Type Parameters
- TValue
The type of the target property.
Parameters
- property
- Expression<Func<TModel,TValue>>
An expression specifying the property to bind.
- getValue
- Func<BindingContext,TValue>
A delegate that gets the value to bind to the target property.