Partager via


ParameterBindingRulesCollection.Add Method (Type, Func<HttpParameterDescriptor, HttpParameterBinding>)

Adds function to the end of the collection. The function added is a wrapper around funcInner that checks that parameterType matches typeMatch.

Namespace:  System.Web.Http.ModelBinding
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Public Sub Add ( _
    typeMatch As Type, _
    funcInner As Func(Of HttpParameterDescriptor, HttpParameterBinding) _
)
'Usage
Dim instance As ParameterBindingRulesCollection 
Dim typeMatch As Type 
Dim funcInner As Func(Of HttpParameterDescriptor, HttpParameterBinding)

instance.Add(typeMatch, funcInner)
public void Add(
    Type typeMatch,
    Func<HttpParameterDescriptor, HttpParameterBinding> funcInner
)
public:
void Add(
    Type^ typeMatch, 
    Func<HttpParameterDescriptor^, HttpParameterBinding^>^ funcInner
)
member Add : 
        typeMatch:Type * 
        funcInner:Func<HttpParameterDescriptor, HttpParameterBinding> -> unit
public function Add(
    typeMatch : Type, 
    funcInner : Func<HttpParameterDescriptor, HttpParameterBinding>
)

Parameters

  • typeMatch
    Type: System.Type

    type to match against HttpParameterDescriptor.ParameterType

See Also

Reference

ParameterBindingRulesCollection Class

Add Overload

System.Web.Http.ModelBinding Namespace