Megosztás a következőn keresztül:


ModelAttributes.GetAttributesForParameter Method

Definition

Overloads

GetAttributesForParameter(ParameterInfo)

Gets the attributes for the given parameterInfo.

GetAttributesForParameter(ParameterInfo, Type)

Gets the attributes for the given parameterInfo with the specified modelType.

GetAttributesForParameter(ParameterInfo)

Source:
ModelAttributes.cs
Source:
ModelAttributes.cs
Source:
ModelAttributes.cs

Gets the attributes for the given parameterInfo.

public:
 static Microsoft::AspNetCore::Mvc::ModelBinding::ModelAttributes ^ GetAttributesForParameter(System::Reflection::ParameterInfo ^ parameterInfo);
public static Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes GetAttributesForParameter (System.Reflection.ParameterInfo parameterInfo);
static member GetAttributesForParameter : System.Reflection.ParameterInfo -> Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes
Public Shared Function GetAttributesForParameter (parameterInfo As ParameterInfo) As ModelAttributes

Parameters

parameterInfo
ParameterInfo

The ParameterInfo for which attributes need to be resolved.

Returns

A ModelAttributes instance with the attributes of the parameter and its Type.

Applies to

GetAttributesForParameter(ParameterInfo, Type)

Source:
ModelAttributes.cs
Source:
ModelAttributes.cs

Gets the attributes for the given parameterInfo with the specified modelType.

public:
 static Microsoft::AspNetCore::Mvc::ModelBinding::ModelAttributes ^ GetAttributesForParameter(System::Reflection::ParameterInfo ^ parameterInfo, Type ^ modelType);
public static Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes GetAttributesForParameter (System.Reflection.ParameterInfo parameterInfo, Type modelType);
static member GetAttributesForParameter : System.Reflection.ParameterInfo * Type -> Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes
Public Shared Function GetAttributesForParameter (parameterInfo As ParameterInfo, modelType As Type) As ModelAttributes

Parameters

parameterInfo
ParameterInfo

The ParameterInfo for which attributes need to be resolved.

modelType
Type

The model type.

Returns

A ModelAttributes instance with the attributes of the parameter and its Type.

Applies to