registry

package
v0.1.0-rc.3 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2025 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PackageID

type PackageID string

PackageID is a unique identifier for a package

type Registry

type Registry interface {
	LoadConcurrency() int
	SetDocumentLoadedCallback(func(*model.Document))
	LoadIndex(indexReader io.ReadSeeker) error
	LoadIndexFile(indexPath string) error
	DidOpen(uri uri.URI, text string) error
	DidClose(uri uri.URI) error

	// GetSymbolDefinitionOccurrence returns the definition occurrence for a given symbol
	GetSymbolDefinitionOccurrence(descriptors []model.Descriptor, version string) (*model.SymbolOccurrence, error)
	// Definition returns the source occurence and the definition occurence for a given position
	Definition(uri uri.URI, loc protocol.Position) (*model.SymbolOccurrence, *model.SymbolOccurrence, error)
	// References returns the locations a symbol is referenced at in the entire index
	References(uri uri.URI, loc protocol.Position) ([]protocol.Location, error)
	// Hover returns the hover information for a given position, as well as it's occurrence
	Hover(uri uri.URI, loc protocol.Position) (string, *model.Occurrence, error)
	// DocumentSymbols returns the document symbols for a given document
	DocumentSymbols(uri uri.URI) ([]*model.SymbolOccurrence, error)
	// Diagnostics returns the diagnostics for a given document
	Diagnostics(uri uri.URI) ([]*model.Diagnostic, error)
	// GetURI gets the full path to a document as an LSP uri.
	GetURI(relPath string) uri.URI
}

Registry is an interface that abstracts SCIP data access

func NewPartialScipRegistry

func NewPartialScipRegistry(workspaceRoot string, indexFolder string, logger *zap.SugaredLogger) Registry

NewPartialScipRegistry creates a new partial SCIP registry

Jump to

Keyboard shortcuts

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