C# 클래스 ExoRule.Validation.PropertyRule

Abstract base for simple validation rules for properties in a model.
상속: Rule, IPropertyRule
파일 보기 프로젝트 열기: vc3/ExoRule

Private Properties

프로퍼티 타입 설명
PropertyRule System

공개 메소드들

메소드 설명
PropertyRule ( string rootType, string property, ConditionType conditionType, RuleInvocationType invocationTypes ) : System

Creates a new PropertyRule for the specified property and condition type.

PropertyRule ( string rootType, string property, ConditionType>.Func conditionType, RuleInvocationType invocationTypes ) : System

Creates a new PropertyRule for the specified property and condition type.

보호된 메소드들

메소드 설명
ConditionApplies ( ModelInstance root ) : bool

Overridden in subclasses to determine if the ConditionType applies.

Format ( ModelType rootType, string property, object value ) : string

Formats the specified value based on the formatting associated with the specified property.

GetErrorCode ( string rootType, string property, string rule ) : string

Generates a unique error code for a property-specific rule.

GetLabel ( ModelType rootType, string property ) : string

Gets the label for the specified property.

GetSourceLabel ( ModelType rootType, string source ) : string

Gets the label for the specified source property path.

InitializePredicates ( ) : void

Initializes predicates for the specified property rule which leverages a comparison property.

OnInvoke ( ModelInstance root, ModelEvent modelEvent ) : void
PropertyRule ( string rootType, string property, RuleInvocationType invocationTypes ) : System

비공개 메소드들

메소드 설명
PropertyRule ( ) : System

Register resources for validation rule subclasses.

메소드 상세

ConditionApplies() 보호된 추상적인 메소드

Overridden in subclasses to determine if the ConditionType applies.
protected abstract ConditionApplies ( ModelInstance root ) : bool
root ModelInstance
리턴 bool

Format() 보호된 정적인 메소드

Formats the specified value based on the formatting associated with the specified property.
protected static Format ( ModelType rootType, string property, object value ) : string
rootType ModelType
property string
value object
리턴 string

GetErrorCode() 보호된 정적인 메소드

Generates a unique error code for a property-specific rule.
protected static GetErrorCode ( string rootType, string property, string rule ) : string
rootType string
property string
rule string
리턴 string

GetLabel() 보호된 정적인 메소드

Gets the label for the specified property.
protected static GetLabel ( ModelType rootType, string property ) : string
rootType ModelType
property string
리턴 string

GetSourceLabel() 보호된 정적인 메소드

Gets the label for the specified source property path.
protected static GetSourceLabel ( ModelType rootType, string source ) : string
rootType ModelType
source string
리턴 string

InitializePredicates() 보호된 메소드

Initializes predicates for the specified property rule which leverages a comparison property.
protected InitializePredicates ( ) : void
리턴 void

OnInvoke() 보호된 메소드

protected OnInvoke ( ModelInstance root, ModelEvent modelEvent ) : void
root ModelInstance
modelEvent ExoModel.ModelEvent
리턴 void

PropertyRule() 공개 메소드

Creates a new PropertyRule for the specified property and condition type.
public PropertyRule ( string rootType, string property, ConditionType conditionType, RuleInvocationType invocationTypes ) : System
rootType string
property string
conditionType ConditionType
invocationTypes RuleInvocationType
리턴 System

PropertyRule() 공개 메소드

Creates a new PropertyRule for the specified property and condition type.
public PropertyRule ( string rootType, string property, ConditionType>.Func conditionType, RuleInvocationType invocationTypes ) : System
rootType string
property string
conditionType ConditionType>.Func
invocationTypes RuleInvocationType
리턴 System

PropertyRule() 보호된 메소드

protected PropertyRule ( string rootType, string property, RuleInvocationType invocationTypes ) : System
rootType string
property string
invocationTypes RuleInvocationType
리턴 System