Class ConsistencyValidator
java.lang.Object
ca.mcscert.jpipe.model.validation.ConsistencyValidator
Checks structural invariants of justification models.
Rules:
no-duplicate-ids— all element IDs within a model are unique.acyclic-support— the support graph contains no cycles (it must be a DAG).acyclic-implements— the implements chain between models contains no cycles.
Note: type constraints (Conclusion ← Strategy ← SupportLeaf) are enforced by the Java type system at construction time and need no runtime check here.
Use validate(Unit) for location-aware validation within a compiler
pipeline. Use validateModel(JustificationModel) for standalone use
when no Unit is available; violations will carry
SourceLocation.UNKNOWN.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionValidates all models in the unit.validateModel(JustificationModel<?> model) Validates a single model without location data.
-
Constructor Details
-
ConsistencyValidator
public ConsistencyValidator()
-
-
Method Details
-
validate
-
validateModel
Validates a single model without location data. All violations carrySourceLocation.UNKNOWN.
-