Learn R Programming

languageserver (version 0.3.1)

DefinitionCache: A data structure to hold function definition locations

Description

The key reason for using this rather than a list is that this also cleans up when functions are removed from files.

Usage

DefinitionCache

Arguments

Format

An object of class R6ClassGenerator of length 24.

Methods

  • get(funct): get the location of a definition, or NULL if it is not found

  • get_functs_for_uri(uri): get the locations of all the definitions in uri

  • filter(pattern): get the locations of all the definitions matching pattern

  • update(uri, ranges): create locations of functions in uri from ranges, and remove functions no longer in uri