16 #ifndef LLVM_CLANG_TOOLS_EXTRA_CLANGD_INDEX_FILEINDEX_H 17 #define LLVM_CLANG_TOOLS_EXTRA_CLANGD_INDEX_FILEINDEX_H 19 #include "../ClangdUnit.h" 22 #include "clang/Lex/Preprocessor.h" 47 std::shared_ptr<std::vector<const Symbol *>>
allSymbols();
50 mutable std::mutex Mutex;
53 llvm::StringMap<std::shared_ptr<SymbolSlab>> FileToSlabs;
61 FileIndex(std::vector<std::string> URISchemes = {});
79 std::vector<std::string> URISchemes;
86 llvm::ArrayRef<std::string> URISchemes = {});
91 #endif // LLVM_CLANG_TOOLS_EXTRA_CLANGD_INDEX_FILEINDEX_H SymbolSlab indexAST(ASTContext &AST, std::shared_ptr< Preprocessor > PP, llvm::ArrayRef< std::string > URISchemes)
Retrieves namespace and class level symbols in AST.
A container of Symbols from several source files.
std::shared_ptr< std::vector< const Symbol * > > allSymbols()
Interface for symbol indexes that can be used for searching or matching symbols among a set of symbol...
This manages symbls from files and an in-memory index on all symbols.
void update(PathRef Path, std::unique_ptr< SymbolSlab > Slab)
Updates all symbols in a file.
llvm::StringRef PathRef
A typedef to represent a ref to file path.
llvm::unique_function< void(llvm::Expected< T >)> Callback
A Callback<T> is a void function that accepts Expected<T>.
This implements an index for a (relatively small) set of symbols that can be easily managed in memory...
std::string Path
A typedef to represent a file path.
===– Representation.cpp - ClangDoc Representation --------—*- C++ -*-===//