27#include <clang/Basic/Version.h>
28#include <clang/Frontend/CompilerInstance.h>
29#include <clang/Tooling/CompilationDatabase.h>
30#include <clang/Tooling/Tooling.h>
31#include <glob/glob.hpp>
60template <
typename ConfigType,
typename DiagramType>
65 DiagramType>::generator;
79 void generate(std::ostream &ostr)
const override;
99template <
typename DiagramModel,
typename DiagramConfig>
107template <
typename C,
typename D>
113 if (!config.allow_empty_diagrams() && model.is_empty()) {
115 "Diagram configuration resulted in empty diagram."};
119 j[
"name"] = model.name();
120 j[
"diagram_type"] =
to_string(model.type());
122 j[
"title"] = config.title();
127 generate_metadata(j);
132template <
typename C,
typename D>
137 parent[
"metadata"][
"schema_version"] =
139 parent[
"metadata"][
"llvm_version"] = clang::getClangFullVersion();