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 1050 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 1087 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 1064 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 792 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 804 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitClassTemplatePartialSpecializationRecord | ( | const ClassTemplatePartialSpecializationRecord * | Record | ) |
Definition at line 837 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitClassTemplateRecord | ( | const ClassTemplateRecord * | Record | ) |
Definition at line 828 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitConceptRecord | ( | const ConceptRecord * | Record | ) |
Definition at line 873 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXClassRecord | ( | const CXXClassRecord * | Record | ) |
Definition at line 818 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXFieldTemplateRecord | ( | const CXXFieldTemplateRecord * | Record | ) |
Definition at line 864 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXMethodRecord | ( | const CXXMethodRecord * | Record | ) |
Definition at line 846 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitCXXMethodTemplateRecord | ( | const CXXMethodTemplateRecord * | Record | ) |
Definition at line 855 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalFunctionRecord | ( | const GlobalFunctionRecord * | Record | ) |
Visit a global function record.
Definition at line 809 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalFunctionTemplateRecord | ( | const GlobalFunctionTemplateRecord * | Record | ) |
Definition at line 900 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalVariableTemplatePartialSpecializationRecord | ( | const GlobalVariableTemplatePartialSpecializationRecord * | Record | ) |
Definition at line 890 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitGlobalVariableTemplateRecord | ( | const GlobalVariableTemplateRecord * | Record | ) |
Definition at line 881 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCCategoryRecord | ( | const ObjCCategoryRecord * | Record | ) |
Definition at line 955 of file SymbolGraphSerializer.cpp.
Referenced by walkUpFromObjCCategoryRecord().
bool SymbolGraphSerializer::visitObjCContainerRecord | ( | const ObjCContainerRecord * | Record | ) |
Definition at line 909 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCInstanceVariableRecord | ( | const ObjCInstanceVariableRecord * | Record | ) |
Definition at line 976 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCInterfaceRecord | ( | const ObjCInterfaceRecord * | Record | ) |
Definition at line 921 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitObjCMethodRecord | ( | const ObjCMethodRecord * | Record | ) |
Definition at line 967 of file SymbolGraphSerializer.cpp.
bool SymbolGraphSerializer::visitTypedefRecord | ( | const TypedefRecord * | Record | ) |
Definition at line 990 of file SymbolGraphSerializer.cpp.
Referenced by walkUpFromTypedefRecord().
bool SymbolGraphSerializer::walkUpFromObjCCategoryRecord | ( | const ObjCCategoryRecord * | Record | ) |
Definition at line 950 of file SymbolGraphSerializer.cpp.
References visitObjCCategoryRecord().
Referenced by traverseObjCCategoryRecord().
bool SymbolGraphSerializer::walkUpFromTypedefRecord | ( | const TypedefRecord * | Record | ) |
Definition at line 982 of file SymbolGraphSerializer.cpp.
References visitTypedefRecord().