index

package
v0.25.0 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Indexer

type Indexer struct {
	// contains filtered or unexported fields
}

func New

func New(parser *parser.Engine, store *store.Store) *Indexer

func NewWithNativeConfig added in v0.5.0

func NewWithNativeConfig(parser *parser.Engine, store *store.Store, cfg native.Config) *Indexer

func (*Indexer) Index

func (i *Indexer) Index(ctx context.Context, root string) (*graph.CodeGraph, core.IndexResult, error)

func (*Indexer) IndexWithOptions added in v0.6.0

func (i *Indexer) IndexWithOptions(ctx context.Context, root string, opts Options) (*graph.CodeGraph, core.IndexResult, error)

func (*Indexer) SetNativeConfig added in v0.5.0

func (i *Indexer) SetNativeConfig(cfg native.Config)

type Options added in v0.6.0

type Options struct {
	// Force re-runs native analyzers and rebuilds edges even when no files
	// changed — needed after toolchain availability changes (e.g. installing
	// go/node makes richer native edges possible without any file edits).
	Force bool
	// SkipNoopGraph makes a no-change index return a nil graph instead of
	// rehydrating the stored one from AllSymbols/AllEdges (a multi-second
	// load on monorepos). Callers that already hold a resident graph — or
	// none at all, like one-shot CLI runs — opt in; result counts still come
	// from the store. The stored-edge invariant (stored == what a rebuild
	// would produce) is untouched.
	SkipNoopGraph bool

	// PrevEdges/PrevSymbols enable incremental edge construction on delta
	// runs (gated additionally by GROVE_INCREMENTAL=1): the caller's
	// resident graph state from the previous index. PrevEdges may be the
	// MERGED (base+native) set — the delta path re-merges fresh native
	// results, and the affected set is widened to every natively
	// re-analyzed package so a vanished native edge cannot strand a stale
	// kept edge. Nil disables the incremental path (full rebuild).
	PrevEdges   []core.Edge
	PrevSymbols []core.SymbolRecord
}

Options controls a single Index run.

Jump to

Keyboard shortcuts

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