clang 20.0.0git
|
The visitor that organizes API information in the Symbol Graph format. More...
#include "clang/ExtractAPI/Serialization/SymbolGraphSerializer.h"
Static Public Member Functions | |
static void | serializeMainSymbolGraph (raw_ostream &OS, const APISet &API, const APIIgnoresList &IgnoresList, SymbolGraphSerializerOption Options={}) |
static void | serializeWithExtensionGraphs (raw_ostream &MainOutput, const APISet &API, const APIIgnoresList &IgnoresList, llvm::function_ref< std::unique_ptr< llvm::raw_pwrite_stream >(llvm::Twine BaseFileName)> CreateOutputStream, SymbolGraphSerializerOption Options={}) |
static std::optional< Object > | serializeSingleSymbolSGF (StringRef USR, const APISet &API) |
Serialize a single symbol SGF. | |
Additional Inherited Members | |
Protected Member Functions inherited from clang::extractapi::APISetVisitor< SymbolGraphSerializer > | |
APISetVisitor (const APISet &API) | |
~APISetVisitor ()=default | |
SymbolGraphSerializer * | getDerived () |
Protected Attributes inherited from clang::extractapi::APISetVisitor< SymbolGraphSerializer > | |
const APISet & | API |
The visitor that organizes API information in the Symbol Graph format.
The Symbol Graph format (https://github.com/apple/swift-docc-symbolkit) models an API set as a directed graph, where nodes are symbol declarations, and edges are relationships between the connected symbols.
Definition at line 74 of file SymbolGraphSerializer.h.
|
inline |
Definition at line 273 of file SymbolGraphSerializer.h.
|
static |
Definition at line 1042 of file SymbolGraphSerializer.cpp.
References clang::extractapi::APISetVisitor< SymbolGraphSerializer >::API, clang::extractapi::APISet::ProductName, and clang::extractapi::APISetVisitor< Derived >::traverseAPISet().
Referenced by clang::ExtractAPIActionBase::ImplEndSourceFileAction().
|
static |
Serialize a single symbol SGF.
This is primarily used for libclang.
std::nullopt
. Definition at line 1079 of file SymbolGraphSerializer.cpp.
References clang::extractapi::APIRecord::Access, clang::extractapi::APISetVisitor< SymbolGraphSerializer >::API, clang::extractapi::APISet::findRecordForUSR(), clang::extractapi::AccessControl::getAccess(), clang::PresumedLoc::getFilename(), clang::extractapi::APISet::getLanguage(), clang::extractapi::APIRecord::IsFromSystemHeader, clang::extractapi::APIRecord::Location, clang::extractapi::APISet::ProductName, and clang::extractapi::APIRecord::USR.
|
static |
Definition at line 1056 of file SymbolGraphSerializer.cpp.
References clang::extractapi::APISetVisitor< SymbolGraphSerializer >::API, clang::extractapi::APISet::ProductName, and clang::extractapi::APISetVisitor< Derived >::traverseAPISet().
Referenced by clang::ExtractAPIActionBase::ImplEndSourceFileAction().
Definition at line 784 of file SymbolGraphSerializer.cpp.
References clang::extractapi::APISetVisitor< SymbolGraphSerializer >::API, and clang::extractapi::APISetVisitor< SymbolGraphSerializer >::traverseAPIRecord().
bool SymbolGraphSerializer::traverseObjCCategoryRecord | ( | const ObjCCategoryRecord * | Record | ) |
Definition at line 796 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitClassTemplatePartialSpecializationRecord | ( | const ClassTemplatePartialSpecializationRecord * | Record | ) |
Definition at line 829 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitClassTemplateRecord | ( | const ClassTemplateRecord * | Record | ) |
Definition at line 820 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitConceptRecord | ( | const ConceptRecord * | Record | ) |
Definition at line 865 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXClassRecord | ( | const CXXClassRecord * | Record | ) |
Definition at line 810 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXFieldTemplateRecord | ( | const CXXFieldTemplateRecord * | Record | ) |
Definition at line 856 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXMethodRecord | ( | const CXXMethodRecord * | Record | ) |
Definition at line 838 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXMethodTemplateRecord | ( | const CXXMethodTemplateRecord * | Record | ) |
Definition at line 847 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalFunctionRecord | ( | const GlobalFunctionRecord * | Record | ) |
Visit a global function record.
Definition at line 801 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalFunctionTemplateRecord | ( | const GlobalFunctionTemplateRecord * | Record | ) |
Definition at line 892 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalVariableTemplatePartialSpecializationRecord | ( | const GlobalVariableTemplatePartialSpecializationRecord * | Record | ) |
Definition at line 882 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalVariableTemplateRecord | ( | const GlobalVariableTemplateRecord * | Record | ) |
Definition at line 873 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCCategoryRecord | ( | const ObjCCategoryRecord * | Record | ) |
Definition at line 947 of file SymbolGraphSerializer.cpp.
Referenced by walkUpFromObjCCategoryRecord().
bool SymbolGraphSerializer::visitObjCContainerRecord | ( | const ObjCContainerRecord * | Record | ) |
Definition at line 901 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCInstanceVariableRecord | ( | const ObjCInstanceVariableRecord * | Record | ) |
Definition at line 968 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCInterfaceRecord | ( | const ObjCInterfaceRecord * | Record | ) |
Definition at line 913 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCMethodRecord | ( | const ObjCMethodRecord * | Record | ) |
Definition at line 959 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitTypedefRecord | ( | const TypedefRecord * | Record | ) |
Definition at line 982 of file SymbolGraphSerializer.cpp.
Referenced by walkUpFromTypedefRecord().
bool SymbolGraphSerializer::walkUpFromObjCCategoryRecord | ( | const ObjCCategoryRecord * | Record | ) |
Definition at line 942 of file SymbolGraphSerializer.cpp.
References visitObjCCategoryRecord().
Referenced by traverseObjCCategoryRecord().
bool SymbolGraphSerializer::walkUpFromTypedefRecord | ( | const TypedefRecord * | Record | ) |
Definition at line 974 of file SymbolGraphSerializer.cpp.
References visitTypedefRecord().