clang 8.0.0

Public Attributes | List of all members
IndexerCallbacks Struct Reference
libclang: C Interface to Clang » Higher level API functions

A group of callbacks used by clang_indexSourceFile and clang_indexTranslationUnit. More...

`#include "clang-c/Index.h"`

Collaboration diagram for IndexerCallbacks:
[legend]

## Public Attributes
int(* | abortQuery )(CXClientData client_data, void *reserved)
| Called periodically to check whether indexing should be aborted. More...
void(* | diagnostic )(CXClientData client_data, CXDiagnosticSet, void *reserved)
| Called at the end of indexing; passes the complete diagnostic set. More...
CXIdxClientFile(* | enteredMainFile )(CXClientData client_data, CXFile mainFile, void *reserved)
CXIdxClientFile(* | ppIncludedFile )(CXClientData client_data, const CXIdxIncludedFileInfo *)
| Called when a file gets #included/#imported. More...
CXIdxClientASTFile(* | importedASTFile )(CXClientData client_data, const CXIdxImportedASTFileInfo *)
| Called when a AST file (PCH or module) gets imported. More...
CXIdxClientContainer(* | startedTranslationUnit )(CXClientData client_data, void *reserved)
| Called at the beginning of indexing a translation unit. More...
void(* | indexDeclaration )(CXClientData client_data, const CXIdxDeclInfo *)
void(* | indexEntityReference )(CXClientData client_data, const CXIdxEntityRefInfo *)
| Called to index a reference of an entity. More...

## Detailed Description

A group of callbacks used by clang_indexSourceFile and clang_indexTranslationUnit.

Definition at line 6416 of file Index.h.

## Member Data Documentation

## ◆ abortQuery

int(* IndexerCallbacks::abortQuery) (CXClientData client_data, void *reserved)

Called periodically to check whether indexing should be aborted.

Should return 0 to continue, and non-zero to abort.

Definition at line 6421 of file Index.h.

## ◆ diagnostic

void(* IndexerCallbacks::diagnostic) (CXClientData client_data, CXDiagnosticSet, void *reserved)

Called at the end of indexing; passes the complete diagnostic set.

Definition at line 6426 of file Index.h.

## ◆ enteredMainFile

CXIdxClientFile(* IndexerCallbacks::enteredMainFile) (CXClientData client_data, CXFile mainFile, void *reserved)

Definition at line 6429 of file Index.h.

## ◆ importedASTFile

CXIdxClientASTFile(* IndexerCallbacks::importedASTFile) (CXClientData client_data, const CXIdxImportedASTFileInfo *)

Called when a AST file (PCH or module) gets imported.

AST files will not get indexed (there will not be callbacks to index all the entities in an AST file). The recommended action is that, if the AST file is not already indexed, to initiate a new indexing job specific to the AST file.

Definition at line 6446 of file Index.h.

## ◆ indexDeclaration

void(* IndexerCallbacks::indexDeclaration) (CXClientData client_data, const CXIdxDeclInfo *)

Definition at line 6455 of file Index.h.

## ◆ indexEntityReference

void(* IndexerCallbacks::indexEntityReference) (CXClientData client_data, const CXIdxEntityRefInfo *)

Called to index a reference of an entity.

Definition at line 6461 of file Index.h.

## ◆ ppIncludedFile

CXIdxClientFile(* IndexerCallbacks::ppIncludedFile) (CXClientData client_data, const CXIdxIncludedFileInfo *)

Called when a file gets #included/#imported.

Definition at line 6435 of file Index.h.

## ◆ startedTranslationUnit

CXIdxClientContainer(* IndexerCallbacks::startedTranslationUnit) (CXClientData client_data, void *reserved)

Called at the beginning of indexing a translation unit.

Definition at line 6452 of file Index.h.

The documentation for this struct was generated from the following file:

- include/clang-c/Index.h