RuleInferrers, special classes that will look at the types of properties and will add rules based upon that.
Configuring rule inferrers
Rule inferrers are configured in thedata.php config file:
Built-in rule inferrers
SometimesRuleInferrer
Will add asometimes rule when the property is optional.
NullableRuleInferrer
Will add anullable rule when the property is nullable.
RequiredRuleInferrer
Will add arequired rule when the property is not nullable.
BuiltInTypesRuleInferrer
Will add rules which are based upon the built-in PHP types:- An
intorfloattype will add thenumericrule - A
booltype will add thebooleanrule - A
stringtype will add thestringrule - An
arraytype will add thearrayrule