ComparableGreaterThanZeroAttribute
Ecng.ComponentModel
Indicates that a comparable value must be greater than zero when provided.
Herda de: ComparableValidationAttribute<T>
Métodos
Validate
protected override bool Validate(T? value, bool disableNullCheck)
result = comparableGreaterThanZeroAttribute.Validate(value, disableNullCheck)
Validates that the value is greater than zero if it is not null.
- value
- The nullable value to validate.
- disableNullCheck
- A flag indicating whether null value should bypass validation.
Retorna: True if the value is null and null checks are disabled, or if the non-null value is greater than zero; otherwise, false.