Langium - v4.0.0
    Preparing search index...

    Class DefaultIndexManager

    The index manager is responsible for keeping metadata about symbols and cross-references in the workspace. It is used to look up symbols in the global scope, mostly during linking and completion. This service is shared between all languages of a language server.

    Implements

    Index

    Constructors

    Properties

    astReflection: AstReflection
    documents: LangiumDocuments
    referenceIndex: Map<string, ReferenceDescription[]> = ...

    This index keeps track of all ReferenceDescription items exported by a document. This is used to compute which elements are affected by a document change and for finding references to an AST node.

    serviceRegistry: ServiceRegistry
    symbolByTypeIndex: ContextCache<string, string, AstNodeDescription[], string> = ...

    This is a cache for the allElements() method. It caches the descriptions from symbolIndex grouped by types.

    symbolIndex: Map<string, AstNodeDescription[]> = ...

    The symbol index stores all AstNodeDescription items exported by a document. The key used in this map is the string representation of the specific document URI.

    Methods

    • Determine whether the given document could be affected by changes of the documents identified by the given URIs (second parameter). The document is typically regarded as affected if it contains a reference to any of the changed files.

      Parameters

      • document: LangiumDocument

        Document to check whether it's affected

      • changedUris: Set<string>

        URIs of the changed documents

      Returns boolean