Hide

YetaWF.Core Package Documentation

Display
Print

YetaWF.Core.Models.ModelBindingErrorManager Class

An instance of this class keeps track of model binding errors for the current request.

Model binding errors are not easily localizable. They are intercepted in Startup Configure (services.AddMvc()) and added to the error list in the ModelBindingErrorManager instance. The base controller implementation has access to the error information and can localize the error message. Components have access to the error information and can use the original "raw" value for rendering if desired. As an example, the DateEdit component uses the attempted value to render an invalid value.

Namespace: YetaWF.Core.Models
Assembly: YetaWF.Core

Inheritance

Syntax

public class ModelBindingErrorManager;

Constructors

PublicModelBindingErrorManagerConstructor.

Fields

PublicStaticAttemptedValueIsInvalidMessageHardcoded message for SetAttemptedValueIsInvalidAccessor, which is used to later localize the message, including reference to the caption if available.

Methods

PublicAddError(not specified)
PublicInherited from System.ObjectEqualsDetermines whether the specified object is equal to the current object.
ProtectedInherited from System.ObjectFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
PublicInherited from System.ObjectGetHashCodeServes as the default hash function.
PublicInherited from System.ObjectGetTypeGets the Type of the current instance.
ProtectedInherited from System.ObjectMemberwiseCloneCreates a shallow copy of the current Object.
PublicStaticInherited from System.ObjectReferenceEqualsDetermines whether the specified Object instances are the same instance.
PublicInherited from System.ObjectToStringReturns a string that represents the current object.
PublicTryGetAttemptedValue(not specified)

See Also YetaWF.Core Overview