Search Results for

    Show / Hide Table of Contents

    Class BetweenValidator

    Defines a data validator for ensuring a value is within a minimum and maximum range.

    Inheritance
    System.Object
    BetweenValidator
    Implements
    IValidator
    Namespace: MADE.Data.Validation.Validators
    Assembly: MADE.Data.Validation.dll
    Syntax
    public class BetweenValidator : object, IValidator

    Constructors

    | Improve this Doc View Source

    BetweenValidator()

    Initializes a new instance of the BetweenValidator class.

    Declaration
    public BetweenValidator()
    | Improve this Doc View Source

    BetweenValidator(IComparable, IComparable)

    Initializes a new instance of the BetweenValidator class with a minimum and maximum range.

    Declaration
    public BetweenValidator(IComparable min, IComparable max)
    Parameters
    Type Name Description
    IComparable min

    The minimum value within the range.

    IComparable max

    The maximum value within the range.

    Properties

    | Improve this Doc View Source

    FeedbackMessage

    Gets or sets the feedback message to display when IsInvalid is true.

    Declaration
    public string FeedbackMessage { get; set; }
    Property Value
    Type Description
    System.String
    | Improve this Doc View Source

    Inclusive

    Gets or sets a value indicating whether the range is inclusive.

    Declaration
    public bool Inclusive { get; set; }
    Property Value
    Type Description
    System.Boolean
    Remarks

    By default, the value is true.

    | Improve this Doc View Source

    IsDirty

    Gets or sets a value indicating whether the data is dirty.

    Declaration
    public bool IsDirty { get; set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    IsInvalid

    Gets or sets a value indicating whether the data provided is in an invalid state.

    Declaration
    public bool IsInvalid { get; set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Key

    Gets or sets the key associated with the validator.

    Declaration
    public string Key { get; set; }
    Property Value
    Type Description
    System.String
    | Improve this Doc View Source

    Max

    Gets or sets the maximum value within the range.

    Declaration
    public IComparable Max { get; set; }
    Property Value
    Type Description
    IComparable
    | Improve this Doc View Source

    Min

    Gets or sets the minimum value within the range.

    Declaration
    public IComparable Min { get; set; }
    Property Value
    Type Description
    IComparable

    Methods

    | Improve this Doc View Source

    Validate(Object)

    Executes data validation on the provided value.

    Declaration
    public void Validate(object value)
    Parameters
    Type Name Description
    System.Object value

    The value to be validated.

    Implements

    IValidator

    Extension Methods

    ReflectionExtensions.GetPropertyValue<T>(Object, String)
    ReflectionExtensions.GetPropertyNames(Object)
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright (c) MADE Apps