Documentation
¶
Overview ¶
Package build holds the dependency graph and two-tier invalidation (FR-061, solution design M5). Tier one covers Go source changes: a changed route registration invalidates the route table and every unit whose generated output embeds route state. Tier two covers .ghtmx changes: a changed unit invalidates itself plus every unit whose diagnostics depend on it — pages referencing its templates and fragments, and files referencing events it declares.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RoutesChanged ¶
RoutesChanged reports whether two route tables differ observably: verbs, paths, handlers, parameters, nav markers, or order-independent membership.
Types ¶
type Graph ¶
type Graph struct {
// contains filtered or unexported fields
}
Graph is the whole-set dependency graph, built from the analyzer's per-file facts. It is immutable; rebuild it after re-analysis.
func NewGraph ¶
func NewGraph(facts map[string]analyzer.DependencyFacts) *Graph
NewGraph builds the graph from the analyzer's dependency facts.
func (*Graph) BoundFiles ¶
BoundFiles returns the units whose generated output embeds route state: tier-one invalidation regenerates exactly these when the route table changes.
func (*Graph) OnTemplateChange ¶
OnTemplateChange returns every unit invalidated by a change to file: the file itself, the transitive closure of units referencing its declarations (a fragment edit invalidates every page rendering it, even through intermediate fragments), and units referencing events the changed file declares. The result is sorted; an unrelated template returns only itself.