Documentation
¶
Index ¶
- Variables
- func FilePath(uri string) (string, error)
- func FileURI(path string) string
- type AnalysisSnapshot
- type AnalysisStore
- func (s *AnalysisStore) Close(uri string)
- func (s *AnalysisStore) Current(uri string) (*AnalysisSnapshot, bool)
- func (s *AnalysisStore) InvalidateAll()
- func (s *AnalysisStore) InvalidateDependencyPath(path string) []string
- func (s *AnalysisStore) InvalidateDependencyPathExcept(path, exceptURI string) []string
- func (s *AnalysisStore) InvalidateGoPackages(root string, packagePaths []string) []string
- func (s *AnalysisStore) InvalidateRoot(root string) []string
- func (s *AnalysisStore) InvalidateURI(uri string)
- func (s *AnalysisStore) Snapshot(root string, document Document) *AnalysisSnapshot
- func (s *AnalysisStore) Transient(root string, document Document, source string) (*goxcompiler.Module, error)
- type CallHierarchyIncomingCall
- type CallHierarchyIncomingCallsParams
- type CallHierarchyItem
- type CallHierarchyOutgoingCall
- type CallHierarchyOutgoingCallsParams
- type CodeAction
- type CodeActionContext
- type CodeActionParams
- type CompletionItem
- type CompletionItemLabelDetails
- type CompletionList
- type CompletionParams
- type CompletionTextEdit
- type CreateFilesParams
- type DeleteFilesParams
- type Diagnostic
- type DidChangeTextDocumentParams
- type DidChangeWatchedFilesParams
- type DidCloseTextDocumentParams
- type DidOpenTextDocumentParams
- type Document
- type DocumentFormattingParams
- type DocumentHighlight
- type DocumentOnTypeFormattingParams
- type DocumentRangeFormattingParams
- type DocumentStore
- func (s *DocumentStore) Change(identifier VersionedTextDocumentIdentifier, ...) error
- func (s *DocumentStore) Close(uri string) bool
- func (s *DocumentStore) Documents() []Document
- func (s *DocumentStore) Get(uri string) (Document, bool)
- func (s *DocumentStore) Len() int
- func (s *DocumentStore) Open(document TextDocumentItem) error
- type DocumentSymbol
- type DocumentSymbolParams
- type FileCreate
- type FileDelete
- type FileEvent
- type FileRename
- type FoldingRange
- type FoldingRangeParams
- type FormattingOptions
- type GoDefinition
- type GoPackage
- type GoPackageCandidate
- type GoPackageExport
- type GoPackageIndex
- func (i *GoPackageIndex) Discover(root string) ([]GoPackageCandidate, error)
- func (i *GoPackageIndex) ExportedPackageDetails(root, importPath string) (GoPackage, error)
- func (i *GoPackageIndex) ExportedPackages(root string) ([]GoPackage, error)
- func (i *GoPackageIndex) Invalidate()
- func (i *GoPackageIndex) InvalidateProjectGoPackage(root, importPath string, affected []string, candidate *GoPackageCandidate)
- func (i *GoPackageIndex) InvalidateRoot(root string)
- func (i *GoPackageIndex) Load(root, importPath string) (GoPackage, error)
- func (i *GoPackageIndex) PackageName(root, importPath string) (string, error)
- func (i *GoPackageIndex) ProjectGoPackageInvalidationForFile(root, filename string) (projectGoPackageInvalidation, bool)
- type GoPackageMember
- type Hover
- type IndexedSymbol
- type InitializeParams
- type InlayHint
- type InlayHintParams
- type LinkedEditingRanges
- type Location
- type LocationLink
- type MarkupContent
- type ParameterInformation
- type Position
- type PrepareRenameResult
- type PublishDiagnosticsParams
- type Range
- type ReferenceContext
- type ReferenceParams
- type RenameFilesParams
- type RenameParams
- type SelectionRange
- type SelectionRangeParams
- type SemanticTokens
- type SemanticTokensParams
- type Server
- type SignatureHelp
- type SignatureHelpParams
- type SignatureInformation
- type SymbolInformation
- type TextDocumentContentChangeEvent
- type TextDocumentIdentifier
- type TextDocumentItem
- type TextDocumentPositionParams
- type TypeHierarchyItem
- type TypeHierarchySubtypesParams
- type TypeHierarchySupertypesParams
- type VersionedTextDocumentIdentifier
- type WorkspaceEdit
- type WorkspaceFolder
- type WorkspaceIndex
- func (i *WorkspaceIndex) ClientSemanticAt(uri string, offset int) (goxcompiler.ClientSemantic, bool)
- func (i *WorkspaceIndex) CloseOpen(uri string)
- func (i *WorkspaceIndex) Definitions(name string) []IndexedSymbol
- func (i *WorkspaceIndex) Document(uri string) (Document, bool)
- func (i *WorkspaceIndex) DocumentSymbols(uri string) []IndexedSymbol
- func (i *WorkspaceIndex) Documents() []Document
- func (i *WorkspaceIndex) GoImports(uri string) []goxcompiler.ImportDecl
- func (i *WorkspaceIndex) Imports(uri string) []goxcompiler.GoxImport
- func (i *WorkspaceIndex) LocalDeclarationAt(uri string, offset int) (goxcompiler.LocalSymbol, bool)
- func (i *WorkspaceIndex) LocalSymbolAt(uri, name string, offset int) (goxcompiler.LocalSymbol, bool)
- func (i *WorkspaceIndex) LocalSymbols(uri string) []goxcompiler.LocalSymbol
- func (i *WorkspaceIndex) ReferenceAt(uri string, offset int) (goxcompiler.SourceReference, bool)
- func (i *WorkspaceIndex) Remove(uri string)
- func (i *WorkspaceIndex) RemoveDisk(uri string)
- func (i *WorkspaceIndex) SelectorReferenceAt(uri string, offset int) (goxcompiler.SelectorReference, bool)
- func (i *WorkspaceIndex) Symbols() []IndexedSymbol
- func (i *WorkspaceIndex) TemplateRanges(uri string) []goxmap.Range
- func (i *WorkspaceIndex) UnresolvedIdentifiers(uri string) []goxcompiler.UnresolvedIdentifier
- func (i *WorkspaceIndex) Update(document Document) error
- func (i *WorkspaceIndex) UpdateDisk(document Document) error
- func (i *WorkspaceIndex) UpdateOpen(document Document) error
- func (i *WorkspaceIndex) UpdateOpenModule(document Document, module *goxcompiler.Module) error
- func (i *WorkspaceIndex) VisibleLocalSymbols(uri string, offset int) []goxcompiler.LocalSymbol
- type WorkspaceSymbolParams
Constants ¶
This section is empty.
Variables ¶
var ( ErrDocumentAlreadyOpen = errors.New("document is already open") ErrDocumentNotOpen = errors.New("document is not open") ErrDocumentVersionNotIncreasing = errors.New("document version is not increasing") ErrIncrementalChangesUnsupported = errors.New("incremental document changes are not supported") )
var ErrExitWithoutShutdown = errors.New("LSP client exited without shutdown")
Functions ¶
Types ¶
type AnalysisSnapshot ¶
type AnalysisSnapshot struct {
Document Document
Root string
Module *goxcompiler.Module
Err error
LastGood *goxcompiler.Module
LastGoodVersion int
Dependencies []goxcompiler.SemanticDependency
// contains filtered or unexported fields
}
AnalysisSnapshot is the immutable semantic analysis owned by one editor document version. Consumers must reuse Module instead of reparsing the same URI/version independently. LastGood deliberately survives a syntactically invalid edit so later phases can use it as a controlled fallback without making stale data the authority for the current version.
type AnalysisStore ¶
type AnalysisStore struct {
// contains filtered or unexported fields
}
AnalysisStore owns canonical analyses for open document versions. Expensive builds happen outside the store lock: equal URI/version requests coalesce on one in-flight build while unrelated documents may analyze concurrently. Invalidations advance a generation so a build that finishes after its input became stale can never repopulate the cache.
func NewAnalysisStore ¶
func NewAnalysisStore() *AnalysisStore
func (*AnalysisStore) Close ¶
func (s *AnalysisStore) Close(uri string)
func (*AnalysisStore) Current ¶
func (s *AnalysisStore) Current(uri string) (*AnalysisSnapshot, bool)
func (*AnalysisStore) InvalidateAll ¶
func (s *AnalysisStore) InvalidateAll()
func (*AnalysisStore) InvalidateDependencyPath ¶
func (s *AnalysisStore) InvalidateDependencyPath(path string) []string
InvalidateDependencyPath removes open snapshots whose semantic dependency graph reaches the changed .gox path. Reverse edges make this lookup proportional to the affected documents rather than the whole workspace.
func (*AnalysisStore) InvalidateDependencyPathExcept ¶
func (s *AnalysisStore) InvalidateDependencyPathExcept(path, exceptURI string) []string
InvalidateDependencyPathExcept is used when an open document changes. Its dependents become stale, but the changed document keeps its previous LastGood until the new version has been analyzed.
func (*AnalysisStore) InvalidateGoPackages ¶
func (s *AnalysisStore) InvalidateGoPackages(root string, packagePaths []string) []string
goPackageDependentURIs returns the open snapshots in root that currently depend on any of packagePaths. C2a deliberately exposes this lookup without changing invalidation behavior; the next phase can consume the same index. InvalidateGoPackages removes only snapshots whose recorded semantic Go package dependencies intersect packagePaths. The semantic importer itself is still one canonical go/types universe per root, so every production .go change rotates that root-wide universe even when unrelated immutable snapshots remain cached.
func (*AnalysisStore) InvalidateRoot ¶
func (s *AnalysisStore) InvalidateRoot(root string) []string
InvalidateRoot drops semantic state belonging to one project root while preserving warm analyses and Go package identities for unrelated workspace folders. It is used for module-metadata changes and conservative fallbacks; ordinary production .go changes use InvalidateGoPackages.
func (*AnalysisStore) InvalidateURI ¶
func (s *AnalysisStore) InvalidateURI(uri string)
func (*AnalysisStore) Snapshot ¶
func (s *AnalysisStore) Snapshot(root string, document Document) *AnalysisSnapshot
func (*AnalysisStore) Transient ¶
func (s *AnalysisStore) Transient(root string, document Document, source string) (*goxcompiler.Module, error)
Transient analyzes repaired editor text without making it authoritative for the document version. The result is cached independently from Snapshot so a repeated completion on the same dangling selector does not rebuild the full semantic workspace on every keystroke/request.
type CallHierarchyIncomingCall ¶
type CallHierarchyIncomingCall struct {
From CallHierarchyItem `json:"from"`
FromRanges []Range `json:"fromRanges"`
}
type CallHierarchyIncomingCallsParams ¶
type CallHierarchyIncomingCallsParams struct {
Item CallHierarchyItem `json:"item"`
}
type CallHierarchyItem ¶
type CallHierarchyOutgoingCall ¶
type CallHierarchyOutgoingCall struct {
To CallHierarchyItem `json:"to"`
FromRanges []Range `json:"fromRanges"`
}
type CallHierarchyOutgoingCallsParams ¶
type CallHierarchyOutgoingCallsParams struct {
Item CallHierarchyItem `json:"item"`
}
type CodeAction ¶
type CodeAction struct {
Title string `json:"title"`
Kind string `json:"kind,omitempty"`
Diagnostics []Diagnostic `json:"diagnostics,omitempty"`
Edit *WorkspaceEdit `json:"edit,omitempty"`
IsPreferred bool `json:"isPreferred,omitempty"`
}
type CodeActionContext ¶
type CodeActionContext struct {
Diagnostics []Diagnostic `json:"diagnostics"`
Only []string `json:"only,omitempty"`
}
type CodeActionParams ¶
type CodeActionParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Range Range `json:"range"`
Context CodeActionContext `json:"context"`
}
type CompletionItem ¶
type CompletionItem struct {
Label string `json:"label"`
LabelDetails *CompletionItemLabelDetails `json:"labelDetails,omitempty"`
Kind int `json:"kind,omitempty"`
Detail string `json:"detail,omitempty"`
InsertText string `json:"insertText,omitempty"`
InsertTextFormat int `json:"insertTextFormat,omitempty"`
FilterText string `json:"filterText,omitempty"`
SortText string `json:"sortText,omitempty"`
TextEdit *CompletionTextEdit `json:"textEdit,omitempty"`
AdditionalTextEdits []CompletionTextEdit `json:"additionalTextEdits,omitempty"`
CandidateType string `json:"-"`
CandidateUnderlying string `json:"-"`
CandidateAlias bool `json:"-"`
CandidateValue string `json:"-"`
CandidateResults []string `json:"-"`
CandidateParameters []goxcompiler.SourceParameter `json:"-"`
}
type CompletionItemLabelDetails ¶
type CompletionItemLabelDetails struct {
Detail string `json:"detail,omitempty"`
Description string `json:"description,omitempty"`
}
CompletionItemLabelDetails uses the LSP label-details presentation so the completion list can show where an otherwise identical symbol comes from. Detail is appended to the label; Description is shown as its provenance.
type CompletionList ¶
type CompletionList struct {
IsIncomplete bool `json:"isIncomplete"`
Items []CompletionItem `json:"items"`
}
type CompletionParams ¶
type CompletionParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
}
type CompletionTextEdit ¶
type CreateFilesParams ¶
type CreateFilesParams struct {
Files []FileCreate `json:"files"`
}
type DeleteFilesParams ¶
type DeleteFilesParams struct {
Files []FileDelete `json:"files"`
}
type Diagnostic ¶
type Diagnostic struct {
Range Range `json:"range"`
Severity int `json:"severity,omitempty"`
Code string `json:"code,omitempty"`
Source string `json:"source,omitempty"`
Message string `json:"message"`
}
func Diagnostics ¶
func Diagnostics(document Document) []Diagnostic
type DidChangeTextDocumentParams ¶
type DidChangeTextDocumentParams struct {
TextDocument VersionedTextDocumentIdentifier `json:"textDocument"`
ContentChanges []TextDocumentContentChangeEvent `json:"contentChanges"`
}
type DidChangeWatchedFilesParams ¶
type DidChangeWatchedFilesParams struct {
Changes []FileEvent `json:"changes"`
}
type DidCloseTextDocumentParams ¶
type DidCloseTextDocumentParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
}
type DidOpenTextDocumentParams ¶
type DidOpenTextDocumentParams struct {
TextDocument TextDocumentItem `json:"textDocument"`
}
type Document ¶
type DocumentFormattingParams ¶
type DocumentFormattingParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Options FormattingOptions `json:"options"`
}
type DocumentHighlight ¶
type DocumentOnTypeFormattingParams ¶
type DocumentOnTypeFormattingParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
Ch string `json:"ch"`
Options FormattingOptions `json:"options"`
}
type DocumentRangeFormattingParams ¶
type DocumentRangeFormattingParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Range Range `json:"range"`
Options FormattingOptions `json:"options"`
}
type DocumentStore ¶
type DocumentStore struct {
// contains filtered or unexported fields
}
func NewDocumentStore ¶
func NewDocumentStore() *DocumentStore
func (*DocumentStore) Change ¶
func (s *DocumentStore) Change(identifier VersionedTextDocumentIdentifier, changes []TextDocumentContentChangeEvent) error
func (*DocumentStore) Close ¶
func (s *DocumentStore) Close(uri string) bool
func (*DocumentStore) Documents ¶
func (s *DocumentStore) Documents() []Document
func (*DocumentStore) Len ¶
func (s *DocumentStore) Len() int
func (*DocumentStore) Open ¶
func (s *DocumentStore) Open(document TextDocumentItem) error
type DocumentSymbol ¶
type DocumentSymbolParams ¶
type DocumentSymbolParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
}
type FileCreate ¶
type FileCreate struct {
URI string `json:"uri"`
}
type FileDelete ¶
type FileDelete struct {
URI string `json:"uri"`
}
type FileRename ¶
type FoldingRange ¶
type FoldingRangeParams ¶
type FoldingRangeParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
}
type FormattingOptions ¶
type GoDefinition ¶
type GoPackage ¶
type GoPackage struct {
Path string
Name string
Definition GoDefinition
Exports []GoPackageExport
}
type GoPackageCandidate ¶
type GoPackageExport ¶
type GoPackageExport struct {
Name string
Detail string
Kind string
Definition GoDefinition
Members []GoPackageMember
Type string
Underlying string
Alias bool
Value string
Results []string
Parameters []goxcompiler.SourceParameter
}
type GoPackageIndex ¶
type GoPackageIndex struct {
// contains filtered or unexported fields
}
func NewGoPackageIndex ¶
func NewGoPackageIndex() *GoPackageIndex
func (*GoPackageIndex) Discover ¶
func (i *GoPackageIndex) Discover(root string) ([]GoPackageCandidate, error)
func (*GoPackageIndex) ExportedPackageDetails ¶
func (i *GoPackageIndex) ExportedPackageDetails(root, importPath string) (GoPackage, error)
ExportedPackageDetails materializes the richer source projection for one package from the file manifest captured while building ExportedPackages. It is intentionally lazy: a global prefix such as Spl should pay detailed AST printing/type-shape extraction only for packages that export matching names.
func (*GoPackageIndex) ExportedPackages ¶
func (i *GoPackageIndex) ExportedPackages(root string) ([]GoPackage, error)
ExportedPackages returns a shallow global export-name index for the standard library and declared module dependencies. It deliberately records only the package, exported identifier, and coarse declaration kind. Completion can therefore reject almost every package using names alone and materialize signatures/types only for packages that actually match the typed prefix.
func (*GoPackageIndex) Invalidate ¶
func (i *GoPackageIndex) Invalidate()
func (*GoPackageIndex) InvalidateProjectGoPackage ¶
func (i *GoPackageIndex) InvalidateProjectGoPackage(root, importPath string, affected []string, candidate *GoPackageCandidate)
InvalidateProjectGoPackage updates only the index layers that can depend on a local module package. Global shallow exports/details describe stdlib and declared module dependencies, so a source edit inside the current module must not evict those expensive root-wide caches.
affected contains the changed package and every local package that imports it transitively. Their typed/source projections may embed types from the changed package and are therefore evicted together. discovery is patched in place for the changed directory so stdlib/dependency inventory remains warm.
func (*GoPackageIndex) InvalidateRoot ¶
func (i *GoPackageIndex) InvalidateRoot(root string)
InvalidateRoot drops only package data associated with one workspace. Other workspace folders keep their warm caches when module metadata changes elsewhere. Local .go edits use InvalidateProjectGoPackage instead.
func (*GoPackageIndex) Load ¶
func (i *GoPackageIndex) Load(root, importPath string) (GoPackage, error)
func (*GoPackageIndex) PackageName ¶
func (i *GoPackageIndex) PackageName(root, importPath string) (string, error)
PackageName resolves only the identifier declared by a Go package. It is intentionally separate from Load: alias resolution during completion must not type-check the package, parse its dependency graph, or build exports just to learn the package clause name.
func (*GoPackageIndex) ProjectGoPackageInvalidationForFile ¶
func (i *GoPackageIndex) ProjectGoPackageInvalidationForFile(root, filename string) (projectGoPackageInvalidation, bool)
ProjectGoPackageInvalidationForFile incrementally updates the persistent local import graph for root and returns the changed package plus its reverse importer closure. The first call for a root builds the graph once; subsequent calls rescan only the changed package directory.
type GoPackageMember ¶
type GoPackageMember struct {
Name string
Detail string
Kind string
Definition GoDefinition
Type string
Underlying string
Alias bool
Results []string
Parameters []goxcompiler.SourceParameter
}
type Hover ¶
type Hover struct {
Contents MarkupContent `json:"contents"`
}
type IndexedSymbol ¶
type IndexedSymbol struct {
URI string
Symbol goxcompiler.SourceSymbol
}
type InitializeParams ¶
type InitializeParams struct {
RootPath string `json:"rootPath,omitempty"`
RootURI string `json:"rootUri,omitempty"`
WorkspaceFolders []WorkspaceFolder `json:"workspaceFolders,omitempty"`
}
type InlayHint ¶
type InlayHint struct {
Position Position `json:"position"`
Label string `json:"label"`
Kind int `json:"kind,omitempty"`
Tooltip *MarkupContent `json:"tooltip,omitempty"`
PaddingRight bool `json:"paddingRight,omitempty"`
}
type InlayHintParams ¶
type InlayHintParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Range Range `json:"range"`
}
type LinkedEditingRanges ¶
type LocationLink ¶
type MarkupContent ¶
type ParameterInformation ¶
type ParameterInformation struct {
Label string `json:"label"`
}
type PrepareRenameResult ¶
type PublishDiagnosticsParams ¶
type PublishDiagnosticsParams struct {
URI string `json:"uri"`
Version int `json:"version,omitempty"`
Diagnostics []Diagnostic `json:"diagnostics"`
}
type ReferenceContext ¶
type ReferenceContext struct {
IncludeDeclaration bool `json:"includeDeclaration"`
}
type ReferenceParams ¶
type ReferenceParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
Context ReferenceContext `json:"context"`
}
type RenameFilesParams ¶
type RenameFilesParams struct {
Files []FileRename `json:"files"`
}
type RenameParams ¶
type RenameParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
NewName string `json:"newName"`
}
type SelectionRange ¶
type SelectionRange struct {
Range Range `json:"range"`
Parent *SelectionRange `json:"parent,omitempty"`
}
type SelectionRangeParams ¶
type SelectionRangeParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Positions []Position `json:"positions"`
}
type SemanticTokens ¶
type SemanticTokens struct {
Data []uint32 `json:"data"`
}
type SemanticTokensParams ¶
type SemanticTokensParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
}
type Server ¶
type Server struct {
// Background starts after the client initializes and stops with the transport.
Background func(context.Context, func(string, any) error)
// contains filtered or unexported fields
}
func (*Server) DocumentCount ¶
func (*Server) SymbolDefinitions ¶
func (s *Server) SymbolDefinitions(name string) []IndexedSymbol
type SignatureHelp ¶
type SignatureHelp struct {
Signatures []SignatureInformation `json:"signatures"`
ActiveSignature int `json:"activeSignature,omitempty"`
ActiveParameter int `json:"activeParameter,omitempty"`
}
type SignatureHelpParams ¶
type SignatureHelpParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
}
type SignatureInformation ¶
type SignatureInformation struct {
Label string `json:"label"`
Parameters []ParameterInformation `json:"parameters,omitempty"`
}
type SymbolInformation ¶
type TextDocumentIdentifier ¶
type TextDocumentIdentifier struct {
URI string `json:"uri"`
}
type TextDocumentItem ¶
type TextDocumentPositionParams ¶
type TextDocumentPositionParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
Position Position `json:"position"`
}
type TypeHierarchyItem ¶
type TypeHierarchySubtypesParams ¶
type TypeHierarchySubtypesParams struct {
Item TypeHierarchyItem `json:"item"`
}
type TypeHierarchySupertypesParams ¶
type TypeHierarchySupertypesParams struct {
Item TypeHierarchyItem `json:"item"`
}
type WorkspaceEdit ¶
type WorkspaceEdit struct {
Changes map[string][]CompletionTextEdit `json:"changes"`
}
type WorkspaceFolder ¶
type WorkspaceIndex ¶
type WorkspaceIndex struct {
// contains filtered or unexported fields
}
WorkspaceIndex keeps compiler-owned declarations for the documents known by the language server. LSP features query this index instead of reparsing GOX.
func NewWorkspaceIndex ¶
func NewWorkspaceIndex() *WorkspaceIndex
func (*WorkspaceIndex) ClientSemanticAt ¶
func (i *WorkspaceIndex) ClientSemanticAt(uri string, offset int) (goxcompiler.ClientSemantic, bool)
func (*WorkspaceIndex) CloseOpen ¶
func (i *WorkspaceIndex) CloseOpen(uri string)
func (*WorkspaceIndex) Definitions ¶
func (i *WorkspaceIndex) Definitions(name string) []IndexedSymbol
func (*WorkspaceIndex) DocumentSymbols ¶
func (i *WorkspaceIndex) DocumentSymbols(uri string) []IndexedSymbol
func (*WorkspaceIndex) Documents ¶
func (i *WorkspaceIndex) Documents() []Document
func (*WorkspaceIndex) GoImports ¶
func (i *WorkspaceIndex) GoImports(uri string) []goxcompiler.ImportDecl
func (*WorkspaceIndex) Imports ¶
func (i *WorkspaceIndex) Imports(uri string) []goxcompiler.GoxImport
func (*WorkspaceIndex) LocalDeclarationAt ¶
func (i *WorkspaceIndex) LocalDeclarationAt(uri string, offset int) (goxcompiler.LocalSymbol, bool)
func (*WorkspaceIndex) LocalSymbolAt ¶
func (i *WorkspaceIndex) LocalSymbolAt(uri, name string, offset int) (goxcompiler.LocalSymbol, bool)
func (*WorkspaceIndex) LocalSymbols ¶
func (i *WorkspaceIndex) LocalSymbols(uri string) []goxcompiler.LocalSymbol
func (*WorkspaceIndex) ReferenceAt ¶
func (i *WorkspaceIndex) ReferenceAt(uri string, offset int) (goxcompiler.SourceReference, bool)
func (*WorkspaceIndex) Remove ¶
func (i *WorkspaceIndex) Remove(uri string)
func (*WorkspaceIndex) RemoveDisk ¶
func (i *WorkspaceIndex) RemoveDisk(uri string)
func (*WorkspaceIndex) SelectorReferenceAt ¶
func (i *WorkspaceIndex) SelectorReferenceAt(uri string, offset int) (goxcompiler.SelectorReference, bool)
func (*WorkspaceIndex) Symbols ¶
func (i *WorkspaceIndex) Symbols() []IndexedSymbol
func (*WorkspaceIndex) TemplateRanges ¶
func (i *WorkspaceIndex) TemplateRanges(uri string) []goxmap.Range
func (*WorkspaceIndex) UnresolvedIdentifiers ¶
func (i *WorkspaceIndex) UnresolvedIdentifiers(uri string) []goxcompiler.UnresolvedIdentifier
func (*WorkspaceIndex) Update ¶
func (i *WorkspaceIndex) Update(document Document) error
func (*WorkspaceIndex) UpdateDisk ¶
func (i *WorkspaceIndex) UpdateDisk(document Document) error
func (*WorkspaceIndex) UpdateOpen ¶
func (i *WorkspaceIndex) UpdateOpen(document Document) error
func (*WorkspaceIndex) UpdateOpenModule ¶
func (i *WorkspaceIndex) UpdateOpenModule(document Document, module *goxcompiler.Module) error
UpdateOpenModule updates the compatibility index from the canonical analysis already owned by AnalysisSnapshot. It prevents didOpen/didChange from reparsing the same document solely to refresh legacy consumers.
func (*WorkspaceIndex) VisibleLocalSymbols ¶
func (i *WorkspaceIndex) VisibleLocalSymbols(uri string, offset int) []goxcompiler.LocalSymbol
type WorkspaceSymbolParams ¶
type WorkspaceSymbolParams struct {
Query string `json:"query"`
}
Source Files
¶
- analysis.go
- analysis_snapshot.go
- assignment_diagnostic.go
- assignment_structure_diagnostic.go
- blank_identifier_diagnostic.go
- call_diagnostic.go
- client_source_completion.go
- client_source_definition.go
- client_source_diagnostic.go
- completion.go
- condition_diagnostic.go
- cursor_context.go
- definition.go
- diagnostic.go
- document.go
- document_format.go
- document_highlight.go
- document_symbol.go
- go_autoimport_completion.go
- go_builtin.go
- go_package_export_scanner.go
- go_package_index.go
- go_package_invalidation.go
- go_stdlib_discovery.go
- go_type_detail.go
- gox_autoimport_completion.go
- gox_sdk_public_api.go
- hierarchy_navigation.go
- hover.go
- import_alias_inlay_hint.go
- import_code_action.go
- import_diagnostic.go
- import_path_completion.go
- imported_go_package_definition.go
- imported_go_package_hover.go
- imported_namespace_hover.go
- linked_editing.go
- protocol.go
- range_format.go
- references.go
- rename.go
- rename_import_alias.go
- return_diagnostic.go
- selector_diagnostic.go
- semantic_completion.go
- semantic_diagnostic.go
- semantic_go.go
- semantic_navigation.go
- semantic_token.go
- server.go
- signature_help.go
- source_origin.go
- struct_literal_completion.go
- structural_range.go
- symbol_quick_fix.go
- template_attribute_completion.go
- template_expression_completion.go
- template_fragment.go
- template_reference_diagnostic.go
- template_sigil_completion.go
- template_snippet_completion.go
- type_navigation.go
- unused_import_diagnostic.go
- unused_local_diagnostic.go
- value_member.go
- workspace_files.go
- workspace_index.go
- workspace_symbol.go
- workspace_type_env.go