graph

package
v3.15.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package graph groups source files into logical subsystems for blueprint record generation.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DirectoryGrouper

type DirectoryGrouper struct{}

DirectoryGrouper groups files by their containing directory.

func (DirectoryGrouper) Group

func (DirectoryGrouper) Group(files []File) ([]Group, error)

Group implements Grouper by clustering files that share a containing directory. Groups are returned sorted by directory name; files within a group are sorted by path. The repo root is named ".".

type File

type File struct {
	Path    string // relative to the scan root
	Lang    lang.Language
	Symbols []symbols.Symbol
	Imports []string
}

File is one source file discovered during a framework-agnostic scan.

type Group

type Group struct {
	Name  string
	Files []File
}

Group is a cluster of related files sharing a grouping identity.

type Grouper

type Grouper interface {
	Group(files []File) ([]Group, error)
}

Grouper clusters discovered files into logical groups for blueprint record generation. Directory grouping (Option A, see DirectoryGrouper) is the default. A future community-detection grouper (Option B — clustering by import graph connectivity) can implement this interface and be substituted in without changing the rest of the discover pipeline.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL