C# Class System.ComponentModel.DataAnnotations.MaxAttribute

Inheritance: System.ComponentModel.DataAnnotations.DataTypeAttribute
Mostra file Open project: adaptabi/i18N-Complete Class Usage Examples

Public Methods

Method Description
FormatErrorMessage ( string name ) : string

Applies formatting to an error message, based on the data field where the error occurred.

IsValid ( object value ) : bool

Determines whether the specified value of the object is valid.

MaxAttribute ( double max ) : System

Creates a new instance of MaxAttribute

MaxAttribute ( int max ) : System

Creates a new instance of MaxAttribute

MaxAttribute ( string errorMessage, double max ) : System

Creates a new instance of MaxAttribute

MaxAttribute ( string errorMessage, int max ) : System

Creates a new instance of MaxAttribute

Method Details

FormatErrorMessage() public method

Applies formatting to an error message, based on the data field where the error occurred.
public FormatErrorMessage ( string name ) : string
name string The name to include in the formatted message.
return string

IsValid() public method

Determines whether the specified value of the object is valid.
public IsValid ( object value ) : bool
value object The value of the object to validate.
return bool

MaxAttribute() public method

Creates a new instance of MaxAttribute
public MaxAttribute ( double max ) : System
max double
return System

MaxAttribute() public method

Creates a new instance of MaxAttribute
public MaxAttribute ( int max ) : System
max int
return System

MaxAttribute() public method

Creates a new instance of MaxAttribute
public MaxAttribute ( string errorMessage, double max ) : System
errorMessage string
max double
return System

MaxAttribute() public method

Creates a new instance of MaxAttribute
public MaxAttribute ( string errorMessage, int max ) : System
errorMessage string
max int
return System