Freigeben über


AssociatedMetadataProvider.GetMetadataForType Methode

Definition

Gibt beim Überschreiben in einer abgeleiteten Klasse Metadaten für den Modelltyp zurück.

public:
 override System::Web::ModelBinding::ModelMetadata ^ GetMetadataForType(Func<System::Object ^> ^ modelAccessor, Type ^ modelType);
public override System.Web.ModelBinding.ModelMetadata GetMetadataForType (Func<object> modelAccessor, Type modelType);
override this.GetMetadataForType : Func<obj> * Type -> System.Web.ModelBinding.ModelMetadata
Public Overrides Function GetMetadataForType (modelAccessor As Func(Of Object), modelType As Type) As ModelMetadata

Parameter

modelAccessor
Func<Object>

Der Modellaccessor.

modelType
Type

Der Typ des Modells.

Gibt zurück

ModelMetadata

Die Metadaten für den Modelltyp.

Ausnahmen

Der modelType-Parameter ist null.

Gilt für