ModelStateDictionaryExtensions.Remove<TModel> 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.
Removes the specified expression
from the ModelStateDictionary.
public:
generic <typename TModel>
[System::Runtime::CompilerServices::Extension]
static bool Remove(Microsoft::AspNetCore::Mvc::ModelBinding::ModelStateDictionary ^ modelState, System::Linq::Expressions::Expression<Func<TModel, System::Object ^> ^> ^ expression);
public static bool Remove<TModel> (this Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState, System.Linq.Expressions.Expression<Func<TModel,object>> expression);
static member Remove : Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary * System.Linq.Expressions.Expression<Func<'Model, obj>> -> bool
<Extension()>
Public Function Remove(Of TModel) (modelState As ModelStateDictionary, expression As Expression(Of Func(Of TModel, Object))) As Boolean
Type Parameters
- TModel
The type of the model.
Parameters
- modelState
- ModelStateDictionary
The ModelStateDictionary instance this method extends.
- expression
- Expression<Func<TModel,Object>>
An expression to be evaluated against an item in the current model.
Returns
true if the element is successfully removed; otherwise, false.
This method also returns false if expression
was not found in the model-state dictionary.
Applies to
Visszajelzés
https://aka.ms/ContentUserFeedback.
Hamarosan elérhető: 2024-ben fokozatosan kivezetjük a GitHub-problémákat a tartalom visszajelzési mechanizmusaként, és lecseréljük egy új visszajelzési rendszerre. További információ:Visszajelzés küldése és megtekintése a következőhöz: