clang  10.0.0svn
Public Member Functions | List of all members
clang::index::FileIndexRecord Class Reference

Stores the declaration occurrences seen in a particular source or header file of a translation unit. More...

#include "/opt/doxygen-docs/src/llvm/tools/clang/lib/Index/FileIndexRecord.h"

Public Member Functions

 FileIndexRecord (FileID FID, bool IsSystem)
 
ArrayRef< DeclOccurrencegetDeclOccurrencesSortedByOffset () const
 
FileID getFileID () const
 
bool isSystem () const
 
void addDeclOccurence (SymbolRoleSet Roles, unsigned Offset, const Decl *D, ArrayRef< SymbolRelation > Relations)
 Adds an occurrence of the canonical declaration D at the supplied Offset. More...
 
void print (llvm::raw_ostream &OS) const
 

Detailed Description

Stores the declaration occurrences seen in a particular source or header file of a translation unit.

Definition at line 26 of file FileIndexRecord.h.

Constructor & Destructor Documentation

◆ FileIndexRecord()

clang::index::FileIndexRecord::FileIndexRecord ( FileID  FID,
bool  IsSystem 
)
inline

Definition at line 33 of file FileIndexRecord.h.

Member Function Documentation

◆ addDeclOccurence()

void FileIndexRecord::addDeclOccurence ( SymbolRoleSet  Roles,
unsigned  Offset,
const Decl D,
ArrayRef< SymbolRelation Relations 
)

Adds an occurrence of the canonical declaration D at the supplied Offset.

Parameters
Rolesthe roles the occurrence fulfills in this position.
Offsetthe offset in the file of this occurrence.
Dthe canonical declaration this is an occurrence of.
Relationsthe set of symbols related to this occurrence.

Definition at line 19 of file FileIndexRecord.cpp.

References clang::Decl::isCanonicalDecl(), clang::Last, and Offset.

Referenced by isSystem().

◆ getDeclOccurrencesSortedByOffset()

ArrayRef<DeclOccurrence> clang::index::FileIndexRecord::getDeclOccurrencesSortedByOffset ( ) const
inline

Definition at line 35 of file FileIndexRecord.h.

◆ getFileID()

FileID clang::index::FileIndexRecord::getFileID ( ) const
inline

Definition at line 39 of file FileIndexRecord.h.

◆ isSystem()

bool clang::index::FileIndexRecord::isSystem ( ) const
inline

Definition at line 40 of file FileIndexRecord.h.

References addDeclOccurence(), Offset, and print().

◆ print()

void FileIndexRecord::print ( llvm::raw_ostream &  OS) const

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