ValidationKit Class

Validates the semantics of Oxbind attributes.

C#
public sealed class ValidationKit
Inheritance
ValidationKit

Constructors

ValidationKit(Journal, QNameBank)

Validates the semantics of Oxbind attributes.

Methods

CheckAttributes(IReadOnlyList<AttributeParameter>)

Checks the constructor parameters attributed with ForAttributeAttribute, ensuring there are no duplicate attribute names, that types are valid, and that ForAttributeAttribute is not combined with other mutually exclusive attributes. Logs errors for any violations found.

CheckChildren(IReadOnlyList<ParameterInfo>)

Validates the constructor parameters that represent child elements. Performs several checks to ensure correct usage of Oxbind child-related attributes, such as [ForText], [Required], [Optional], and [Multiple]. Logs errors for invalid combinations or missing annotations.

Equals(object) (Inherited from object)
GetHashCode() (Inherited from object)
GetType() (Inherited from object)
MemberwiseClone() (Inherited from object)
ToString() (Inherited from object)

Constructors Detail

ValidationKit(Journal, QNameBank)

Validates the semantics of Oxbind attributes.

C#
public ValidationKit(Journal journal, QNameBank nameBank)

Parameters

journal
Journal

The Journal instance.

nameBank
QNameBank

The QNameBank instance used to intern XML qualified names.

Methods Detail

CheckAttributes(IReadOnlyList<AttributeParameter>)

Checks the constructor parameters attributed with ForAttributeAttribute, ensuring there are no duplicate attribute names, that types are valid, and that ForAttributeAttribute is not combined with other mutually exclusive attributes. Logs errors for any violations found.

C#
public void CheckAttributes(IReadOnlyList<AttributeParameter> attributeParameterList)

Parameters

attributeParameterList
IReadOnlyList<AttributeParameter>

The list of AttributeParameter objects representing constructor parameters attributed with ForAttributeAttribute.

CheckChildren(IReadOnlyList<ParameterInfo>)

Validates the constructor parameters that represent child elements. Performs several checks to ensure correct usage of Oxbind child-related attributes, such as [ForText], [Required], [Optional], and [Multiple]. Logs errors for invalid combinations or missing annotations.

C#
public Dependency CheckChildren(IReadOnlyList<ParameterInfo> childParameterList)

Parameters

childParameterList
IReadOnlyList<ParameterInfo>

The list of constructor parameters to validate as child elements.

Returns

The Dependency object representing the child element dependencies.