#pragma once #include "Support/Support.h" #include "clang/Tooling/CompilationDatabase.h" namespace clice { class CommandManager { public: void update(llvm::StringRef dir); /// Return the commands of first meet file. llvm::StringRef lookupFirst(llvm::StringRef file); llvm::ArrayRef lookup(llvm::StringRef file); private: /// CDB file -> file -> [commands] using Commands = std::vector; using CDB = llvm::StringMap; llvm::StringMap CDBs; }; } // namespace clice