clang  8.0.0svn
Classes | Public Member Functions | List of all members
clang::index::IndexDataConsumer Class Reference

#include "clang/Index/IndexDataConsumer.h"

Classes

struct  ASTNodeInfo
 

Public Member Functions

virtual ~IndexDataConsumer ()
 
virtual void initialize (ASTContext &Ctx)
 
virtual void setPreprocessor (std::shared_ptr< Preprocessor > PP)
 
virtual bool handleDeclOccurence (const Decl *D, SymbolRoleSet Roles, ArrayRef< SymbolRelation > Relations, SourceLocation Loc, ASTNodeInfo ASTNode)
 
virtual bool handleMacroOccurence (const IdentifierInfo *Name, const MacroInfo *MI, SymbolRoleSet Roles, SourceLocation Loc)
 
virtual bool handleModuleOccurence (const ImportDecl *ImportD, const Module *Mod, SymbolRoleSet Roles, SourceLocation Loc)
 
virtual void finish ()
 

Detailed Description

Definition at line 27 of file IndexDataConsumer.h.

Constructor & Destructor Documentation

◆ ~IndexDataConsumer()

virtual clang::index::IndexDataConsumer::~IndexDataConsumer ( )
inlinevirtual

Definition at line 36 of file IndexDataConsumer.h.

Member Function Documentation

◆ finish()

virtual void clang::index::IndexDataConsumer::finish ( )
inlinevirtual

◆ handleDeclOccurence()

bool IndexDataConsumer::handleDeclOccurence ( const Decl D,
SymbolRoleSet  Roles,
ArrayRef< SymbolRelation Relations,
SourceLocation  Loc,
ASTNodeInfo  ASTNode 
)
virtual
Returns
true to continue indexing, or false to abort.

Definition at line 25 of file IndexingAction.cpp.

Referenced by setPreprocessor(), and shouldReportOccurrenceForSystemDeclOnlyMode().

◆ handleMacroOccurence()

bool IndexDataConsumer::handleMacroOccurence ( const IdentifierInfo Name,
const MacroInfo MI,
SymbolRoleSet  Roles,
SourceLocation  Loc 
)
virtual
Returns
true to continue indexing, or false to abort.

Definition at line 32 of file IndexingAction.cpp.

Referenced by indexPreprocessorMacros(), and setPreprocessor().

◆ handleModuleOccurence()

bool IndexDataConsumer::handleModuleOccurence ( const ImportDecl ImportD,
const Module Mod,
SymbolRoleSet  Roles,
SourceLocation  Loc 
)
virtual
Returns
true to continue indexing, or false to abort.

This will be called for each module reference in an import decl. For "@import MyMod.SubMod", there will be a call for 'MyMod' with the 'reference' role, and a call for 'SubMod' with the 'declaration' role.

Definition at line 39 of file IndexingAction.cpp.

Referenced by clang::index::IndexingContext::importedModule(), and reportModuleReferences().

◆ initialize()

virtual void clang::index::IndexDataConsumer::initialize ( ASTContext Ctx)
inlinevirtual

◆ setPreprocessor()

virtual void clang::index::IndexDataConsumer::setPreprocessor ( std::shared_ptr< Preprocessor PP)
inlinevirtual

Definition at line 40 of file IndexDataConsumer.h.

References handleDeclOccurence(), and handleMacroOccurence().

Referenced by clang::index::indexASTUnit().


The documentation for this class was generated from the following files: