Class RequiredAllowWhitespaceAttribute
- Namespace
- Acuit.Pinpoint.Common.Validation
- Assembly
- Acuit.Pinpoint.Common.dll
Specifies that a data field value is required.
[AttributeUsage(AttributeTargets.Property|AttributeTargets.Field|AttributeTargets.Parameter, AllowMultiple = false)]
public sealed class RequiredAllowWhitespaceAttribute : RequiredAttribute, _Attribute
- Inheritance
-
RequiredAllowWhitespaceAttribute
- Implements
- Inherited Members
Remarks
This works just like RequiredAttribute, except that it does not trim the string value when performing its check, so values containing only whitespace will be considered valid.
Methods
IsValid(object)
Checks whether the specified object is valid.
public override bool IsValid(object value)
Parameters
value
objectThe value of the object to validate.