Documentation
¶
Overview ¶
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
ENGMODEL-OWNER-UNIT: FU-VALIDATION-ENGINE
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HasErrors ¶
func HasErrors(diags []Diagnostic) bool
ENGMODEL-LINKS: FU-VALIDATION-ENGINE, CTRL-TRACEABILITY-COVERAGE, STATE-MODEL-VALID, STATE-MODEL-INVALID, EVT-VALIDATION-FAILED TRLC-LINKS: REQ-EMG-001, REQ-EMG-009, REQ-EMG-011
Types ¶
type Diagnostic ¶
type Diagnostic struct {
Code string `json:"code"`
Severity Severity `json:"severity"`
Message string `json:"message"`
Path string `json:"path,omitempty"`
}
ENGMODEL-LINKS: FU-VALIDATION-ENGINE, CTRL-TRACEABILITY-COVERAGE, STATE-MODEL-VALID, STATE-MODEL-INVALID, EVT-VALIDATION-FAILED
func Bundle ¶
func Bundle(b model.Bundle) []Diagnostic
ENGMODEL-LINKS: FU-VALIDATION-ENGINE, CTRL-TRACEABILITY-COVERAGE, STATE-MODEL-VALID, STATE-MODEL-INVALID, EVT-VALIDATION-FAILED, FU-VIEW-PROJECTION TRLC-LINKS: REQ-EMG-001, REQ-EMG-009, REQ-EMG-011, REQ-EMG-035, REQ-EMG-036, REQ-EMG-037, REQ-EMG-041, REQ-EMG-043, REQ-EMG-049, REQ-EMG-065, REQ-EMG-070
func DedupeDiagnostics ¶
func DedupeDiagnostics(lists ...[]Diagnostic) []Diagnostic
DedupeDiagnostics merges diagnostic lists produced by separate checks of one run (for example document generation and the trace check, which both run the trace-integrity check) so each finding is reported once. Diagnostics are identified by code, path and message; the first occurrence keeps its position, and an error severity on any duplicate wins over a warning. ENGMODEL-LINKS: FU-VALIDATION-ENGINE, CTRL-TRACEABILITY-COVERAGE, EVT-VALIDATION-FAILED TRLC-LINKS: REQ-EMG-001, REQ-EMG-009, REQ-EMG-011
func SortDiagnostics ¶
func SortDiagnostics(in []Diagnostic) []Diagnostic
ENGMODEL-LINKS: FU-VALIDATION-ENGINE, CTRL-TRACEABILITY-COVERAGE, STATE-MODEL-VALID, STATE-MODEL-INVALID, EVT-VALIDATION-FAILED TRLC-LINKS: REQ-EMG-001, REQ-EMG-009, REQ-EMG-011, REQ-EMG-012
type RelationshipPair ¶
type RelationshipPair struct {
Type string `json:"type"`
From string `json:"from"`
To string `json:"to"`
}
RelationshipPair is one allowed authoredArchitecture.mappings type with the entity kinds of its from and to ends. ENGMODEL-LINKS: FU-VALIDATION-ENGINE, DO-MODEL-AUTHORING-CONTRACT
type Rules ¶
type Rules struct {
Enums map[string][]string `json:"enums"`
RelationshipPairs []RelationshipPair `json:"relationshipPairs"`
FieldRules []string `json:"fieldRules"`
}
Rules is the machine-readable subset of the validation rules that agents need before authoring YAML: controlled vocabularies, allowed relationship kind pairs and cross-reference field rules. It is derived from the same tables Bundle uses, so it cannot drift from validation. ENGMODEL-LINKS: FU-VALIDATION-ENGINE, DO-MODEL-AUTHORING-CONTRACT
func AuthoringRules ¶
func AuthoringRules() Rules
AuthoringRules returns the validation vocabularies and relationship pairs as sorted, deterministic data for the model authoring contract. TRLC-LINKS: REQ-EMG-045, REQ-EMG-009 ENGMODEL-LINKS: FU-VALIDATION-ENGINE, DO-MODEL-AUTHORING-CONTRACT