Enumeration ConditionCategory

Each Category gets assigned a category. For the most part, these are merely info. However, Require and DataTypeCheck have special meaning. Require - the InputValueHostConfig.requiresInput property is set if this is found. These conditions are always placed first in the evaluation order. When Require, ValidatorConfig.severity of Undefined is treated as Severe, not Error to stop further Condition evaluation. DataTypeCheck - used to ensure we have a valid native object that can be used by other conditions. Because these should be evaluated before those, these conditions are placed just after Require. When DataTypeCheck, ValidatorConfig.severity of Undefined is treated as Severe, not Error, to stop further Condition evaluation. Users may set RegExpCondition's Category to DataTypeCheck if the expression confirms a string is the expected data type, like USPhoneNumber or EmailAddress. In fact, these categories determine a sort order for the Conditions on one ValidatorsValueHostBase. Thus, its imperitive we preserve the order of first two.

Enumeration Members

Require: 0

Use when the data is required: RequireTextCondition. These will be evaluated first by the ValidatorsValueHostBase, and will stop further evaluation if evaluation is NoMatch (unless user explicitly sets ValidatorConfig.severity to Error or Warning.)

DataTypeCheck: 1

Use to check the data is in its expected final form, whether a primitive, object (like Date), or if it remains a string, it contains the expected pattern: DataTypeCheckCondition, RegExpCondition These will be evaluated before all other conditions except Require, and will stop further evaluation if evaluation is NoMatch (unless user explicitly sets ValidatorConfig.severity to Error or Warning.)

Comparison: 2

Provides logical comparison: EqualToCondition, GreaterThanCondition, etc.

Contents: 3

For string data that is expected to have specific contents, but isn't required to conform to the data type. For example, a postal code is a good DataTypeCheck regular expression. If you want to include specific postal codes, you might use a regular expression and its category would be Contents.

Children: 4

Evaluation is based on the evaluation results of Child conditions. Generally these inherit from ConditionWithChildrenBase or ConditionWithOneChildBase

Undetermined: 5

For anything else.

Generated using TypeDoc v0.25.12