SchemaValidationVisitor Class

A SchemaWalkerVisitor interface implementation that is used to validate ECObjects schemas using IRuleSet objects registered with the instance. Also allows for reporting of IDiagnostic objects returned from failing rules using IDiagnosticReporter implementations registered with an instance of this class.

Implements

Methods

Name Description
constructor(): SchemaValidationVisitor    
applyClassRules(ecClass: AnyClass, ruleSet: IRuleSet): Promise<void>    
applyConstantRules(constant: Constant, ruleSet: IRuleSet): Promise<void>    
applyCustomAttributeContainerRules(container: CustomAttributeContainerProps, ruleSet: IRuleSet): Promise<void>    
applyCustomAttributeInstanceRules(container: CustomAttributeContainerProps, customAttribute: CustomAttribute, ruleSet: IRuleSet): Promise<void>    
applyCustomAttributeRules(customAttribute: CustomAttributeClass, ruleSet: IRuleSet): Promise<void>    
applyEntityRules(entityClass: EntityClass, ruleSet: IRuleSet): Promise<void>    
applyEnumerationRules(enumeration: Enumeration, ruleSet: IRuleSet): Promise<void>    
applyFormatRules(format: Format, ruleSet: IRuleSet): Promise<void>    
applyInvertedUnitRules(invertedUnit: InvertedUnit, ruleSet: IRuleSet): Promise<void>    
applyKindOfQuantityRules(kindOfQuantity: KindOfQuantity, ruleSet: IRuleSet): Promise<void>    
applyMixinRules(mixin: Mixin, ruleSet: IRuleSet): Promise<void>    
applyPhenomenonRules(phenomenon: Phenomenon, ruleSet: IRuleSet): Promise<void>    
applyPropertyCategoryRules(propertyCategory: PropertyCategory, ruleSet: IRuleSet): Promise<void>    
applyPropertyRules(property: AnyProperty, ruleSet: IRuleSet): Promise<void>    
applyRelationshipConstraintRules(constraint: RelationshipConstraint, ruleSet: IRuleSet): Promise<void>    
applyRelationshipRules(relationship: RelationshipClass, ruleSet: IRuleSet): Promise<void>    
applySchemaItemRules(schemaItem: SchemaItem, ruleSet: IRuleSet): Promise<void>    
applySchemaRules(schema: Schema, ruleSet: IRuleSet): Promise<void>    
applyStructRules(structClass: StructClass, ruleSet: IRuleSet): Promise<void>    
applyUnitRules(unit: Unit, ruleSet: IRuleSet): Promise<void>    
applyUnitSystemRules(unitSystem: UnitSystem, ruleSet: IRuleSet): Promise<void>    
registerReporter(...reporters: IDiagnosticReporter[]): void Registers a IDiagnosticReporter allowing the reporter to be  
registerRuleSet(ruleSet: IRuleSet): void Registers a IRuleSet that will applied during schema traversal.  
registerRuleSuppressionSet(suppressionSet: IRuleSuppressionSet): void Registers a IRuleSuppressionSet that will be applied during schema traversal.  
visitClass(ecClass: AnyClass): Promise<void> Called for each AnyClass instance found during schema traversal.  
visitConstant(constant: Constant): Promise<void> Called for each Constant instance found during schema traversal.  
visitCustomAttributeClass(customAttribute: CustomAttributeClass): Promise<void> Called for each CustomAttributeClass instance found during schema traversal.  
visitCustomAttributeContainer(container: CustomAttributeContainerProps): Promise<void> Called for each CustomAttribute container in the schema.  
visitEntityClass(entity: EntityClass): Promise<void> Called for each EntityClass instance found during schema traversal.  
visitEnumeration(enumeration: Enumeration): Promise<void> Called for each Enumeration instance found during schema traversal.  
visitFormat(format: Format): Promise<void> Called for each Format instance found during schema traversal.  
visitFullSchema(schema: Schema): Promise<void> Called before schema traversal.  
visitInvertedUnit(invertedUnit: InvertedUnit): Promise<void> Called for each InvertedUnit instance found during schema traversal.  
visitKindOfQuantity(koq: KindOfQuantity): Promise<void> Called for each KindOfQuantity instance found during schema traversal.  
visitMixin(mixin: Mixin): Promise<void> Called for each Mixin instance found during schema traversal.  
visitPhenomenon(phenomenon: Phenomenon): Promise<void> Called for each Phenomenon instance found during schema traversal.  
visitProperty(property: AnyProperty): Promise<void> Called for each AnyProperty instance of an ECClass.  
visitPropertyCategory(category: PropertyCategory): Promise<void> Called for each PropertyCategory instance found during schema traversal.  
visitRelationshipClass(relationship: RelationshipClass): Promise<void> Called for each RelationshipClass instance found during schema traversal.  
visitRelationshipConstraint(constraint: RelationshipConstraint): Promise<void> Called for each RelationshipConstraint of each RelationshipClass found during schema traversal.  
visitSchemaItem(schemaItem: SchemaItem): Promise<void> Called for each SchemaItem instance found during schema traversal.  
visitStructClass(struct: StructClass): Promise<void> Called for each StructClass instance found during schema traversal.  
visitUnit(unit: Unit): Promise<void> Called for each Unit instance found during schema traversal.  
visitUnitSystem(unitSystem: UnitSystem): Promise<void> Called for each UnitSystem instance found during schema traversal.  

Properties

Name Type Description
diagnosticReporters Accessor ReadOnly IDiagnosticReporter[] Gets the IDiagnosticReporter objects registered with the visitor.  
ruleSets Accessor ReadOnly RuleSetArray Gets the IRule objects registered with the visitor.  
suppressionSet Accessor ReadOnly undefined | IRuleSuppressionSet    

Defined in

Last Updated: 17 December, 2024