C# Class HandCoded.Validation.Rule

A Rule instance encapsulates a validation rule that can be tested against a XmlDocument.
Inheritance: Validator
Datei anzeigen Open project: formicary/fpml-toolkit-csharp Class Usage Examples

Public Methods

Method Description
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.

Protected Methods

Method Description
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.

Method Details

AppliesTo() public method

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.
return bool

ForName() public static method

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.
return Rule

Rule() protected method

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.
return System

Rule() protected method

Constructs a Rule that applies to any document.
protected Rule ( string name ) : System
name string The unique name for the rule.
return System