C# Class ExoRule.Validation.RequiredRule

Applies conditions when the value of a ModelProperty is null or an empty list.
Inheritance: PropertyRule
Afficher le fichier Open project: vc3/ExoRule

Méthodes publiques

Méthode Description
RequiredRule ( string rootType, string property ) : System
RequiredRule ( string rootType, string property, Error error ) : System
RequiredRule ( string rootType, string property, Error error, object requiredValue ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, Error error ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, Error error, object requiredValue ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, object requiredValue ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, string errorMessage ) : System
RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, string errorMessage, object requiredValue ) : System
RequiredRule ( string rootType, string property, object requiredValue ) : System
RequiredRule ( string rootType, string property, string errorMessage ) : System
RequiredRule ( string rootType, string property, string errorMessage, object requiredValue ) : System

Méthodes protégées

Méthode Description
ConditionApplies ( ModelInstance root ) : bool

Determines whether the rule should attach its condition to the given ModelInstance.

Private Methods

Méthode Description
CreateError ( string property ) : ConditionType>.Func

Method Details

ConditionApplies() protected méthode

Determines whether the rule should attach its condition to the given ModelInstance.
protected ConditionApplies ( ModelInstance root ) : bool
root ModelInstance The model instance to evaluate the rule for.
Résultat bool

RequiredRule() public méthode

public RequiredRule ( string rootType, string property ) : System
rootType string
property string
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, Error error ) : System
rootType string
property string
error Error
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, Error error, object requiredValue ) : System
rootType string
property string
error Error
requiredValue object
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes ) : System
rootType string
property string
invocationTypes RuleInvocationType
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, Error error ) : System
rootType string
property string
invocationTypes RuleInvocationType
error Error
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, Error error, object requiredValue ) : System
rootType string
property string
invocationTypes RuleInvocationType
error Error
requiredValue object
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, object requiredValue ) : System
rootType string
property string
invocationTypes RuleInvocationType
requiredValue object
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, string errorMessage ) : System
rootType string
property string
invocationTypes RuleInvocationType
errorMessage string
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, RuleInvocationType invocationTypes, string errorMessage, object requiredValue ) : System
rootType string
property string
invocationTypes RuleInvocationType
errorMessage string
requiredValue object
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, object requiredValue ) : System
rootType string
property string
requiredValue object
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, string errorMessage ) : System
rootType string
property string
errorMessage string
Résultat System

RequiredRule() public méthode

public RequiredRule ( string rootType, string property, string errorMessage, object requiredValue ) : System
rootType string
property string
errorMessage string
requiredValue object
Résultat System