C# Класс HandCoded.Validation.Rule

A Rule instance encapsulates a validation rule that can be tested against a XmlDocument.
Наследование: Validator
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AppliesTo ( NodeIndex nodeIndex ) : bool

Determines if the Rule applies to a document but evaluating its Precondition.

ForName ( string name ) : Rule

Returns a reference to the named Rule instance if it exists.

Защищенные методы

Метод Описание
Rule ( Precondition precondition, string name ) : System

Constructs a Rule with the given name and that applies in the circumstances defines by its Precondition.

Rule ( string name ) : System

Constructs a Rule that applies to any document.

Описание методов

AppliesTo() публичный Метод

Determines if the Rule applies to a document but evaluating its Precondition.
public AppliesTo ( NodeIndex nodeIndex ) : bool
nodeIndex HandCoded.Xml.NodeIndex The of the document.
Результат bool

ForName() публичный статический Метод

Returns a reference to the named Rule instance if it exists.
public static ForName ( string name ) : Rule
name string The name of the required Rule.
Результат Rule

Rule() защищенный Метод

Constructs a Rule with the given name and that applies in the circumstances defines by its Precondition.
protected Rule ( Precondition precondition, string name ) : System
precondition Precondition A instance.
name string The unique name for the rule.
Результат System

Rule() защищенный Метод

Constructs a Rule that applies to any document.
protected Rule ( string name ) : System
name string The unique name for the rule.
Результат System