Class ValidationRuleDefinition
Definition of a registered form component validation rule.
[Obsolete("This is a legacy validation rule framework for form fields that will eventually become unsupported.")]
public class ValidationRuleDefinition : ComponentDefinitionBase, IFormBuilderDefinition, IComponentDefinition
- Inheritance
-
objectValidationRuleDefinition
- Implements
- Inherited Members
- Extension Methods
Constructors
ValidationRuleDefinition(string, Type, string)
Initializes a new instance of the ValidationRuleDefinition class using given identifier, form component validation rule type and name.
public ValidationRuleDefinition(string identifier, Type validationRuleType, string name)
Parameters
identifierstringUnique identifier of the form component validation rule.
validationRuleTypeTypeType of the form component validation rule.
namestringName of the form component validation rule.
Exceptions
- ArgumentException
Specified
identifieris null, an empty string or identifier does not specify a valid code name.-or-
Specified
validationRuleTypedoes not inherit ValidationRule, is an abstract type or is a generic type which is not constructed.-or-
Specified
nameis null or an empty string.- ArgumentNullException
Thrown when
validationRuleTypeis null.
Properties
Description
Gets or sets the description of the form component validation rule.
public string Description { get; set; }
Property Value
- string
ValidatedDataType
Value type, which this validation rule is supposed to validate.
public Type ValidatedDataType { get; }
Property Value
- Type
ValidationRuleType
Gets the type of the form component validation rule. The type inherits ValidationRule.
public Type ValidationRuleType { get; }
Property Value
- Type