C# Class Adf.Base.Validation.MaxDataLengthAttribute

Inheritance: System.Attribute, IPropertyValidator
Mostra file Open project: NLADP/ADF

Public Methods

Method Description
IsValid ( PropertyInfo propertyToValidate, object value ) : ValidationResult

Determines whether the specified value is valid for the supplied property.

MaxDataLengthAttribute ( int precision, int scale ) : System

Creates a new MaxLengthAttribute instance with the supplied data length.

Private Methods

Method Description
HasMaxDataLength ( object value, int precision, int scale ) : bool

Method Details

IsValid() public method

Determines whether the specified value is valid for the supplied property.
public IsValid ( PropertyInfo propertyToValidate, object value ) : ValidationResult
propertyToValidate System.Reflection.PropertyInfo The supplied property.
value object The supplied value.
return ValidationResult

MaxDataLengthAttribute() public method

Creates a new MaxLengthAttribute instance with the supplied data length.
public MaxDataLengthAttribute ( int precision, int scale ) : System
precision int The supplied precision.
scale int The supplied scale.
return System