kdevelop/kdevplatform/language/duchain
declarationid.cpp
Go to the documentation of this file.
154 Declaration* DeclarationId::declaration(const TopDUContext* top, bool instantiateIfRequired) const
205 topContextForSpecialization = nullptr; //If we don't want to instantiate new declarations, set the top-context to zero, so specialize(..) will only look-up
Represents a single declaration in a definition-use chain.
Definition: declaration.h:51
bool isDirect() const
Determine whether this DeclarationId directly references a Declaration by indices, or if it uses identifiers and other data to reference the Declaration.
Definition: declarationid.cpp:82
Declaration * declaration() const
Definition: indexeddeclaration.cpp:44
Declaration * declaration(const TopDUContext *context, bool instantiateIfRequired=true) const
Retrieve the declaration, from the perspective of context.
Definition: declarationid.cpp:154
KDevVarLengthArray< Declaration * > declarations(const TopDUContext *context) const
Same as declaration(..), but returns all matching declarations if there are multiple.
Definition: declarationid.cpp:97
virtual bool isForwardDeclaration() const
Determine whether this declaration is a forward declaration.
Definition: declaration.cpp:653
void setSpecialization(const IndexedInstantiationInformation &spec)
Set the specialization index (see class documentation).
Definition: declarationid.cpp:87
FilteredDeclarationIterator filteredDeclarations(const IndexedQualifiedIdentifier &id, const TopDUContext::IndexedRecursiveImports &visibility) const
Retrieves an iterator to all declarations of the given id, filtered by the visibility given through v...
Definition: persistentsymboltable.cpp:318
The top context in a definition-use chain for one source file.
Definition: topducontext.h:113
Represents a declaration only by its global indices.
Definition: indexeddeclaration.h:33
static PersistentSymbolTable & self()
Definition: persistentsymboltable.cpp:486
A helper-class to store an identifier by index in a type-safe way.
Definition: identifier.h:95
ConstantConvenientEmbeddedSet< IndexedDeclaration, IndexedDeclarationHandler > Declarations
Definition: persistentsymboltable.h:128
virtual uint additionalIdentity() const
This hash-value should differentiate between multiple different declarations that have the same quali...
Definition: declaration.cpp:663
IndexedInstantiationInformation specialization() const
Retrieve the specialization index (see class documentation).
Definition: declarationid.cpp:92
TopDUContext * topContext() const override
Determine the top context to which this object belongs.
Definition: declaration.cpp:636
DeclarationId(const IndexedQualifiedIdentifier &id=IndexedQualifiedIdentifier(), uint additionalId=0, const IndexedInstantiationInformation &specialization=IndexedInstantiationInformation())
Constructor for indirect access to a declaration.
Definition: declarationid.cpp:31
DeclarationId & operator=(const DeclarationId &rhs)
Definition: declarationid.cpp:67
const IndexedRecursiveImports & recursiveImportIndices() const
Returns the set of all recursively imported top-contexts.
Definition: topducontext.cpp:384
void declarations(const IndexedQualifiedIdentifier &id, uint &count, const IndexedDeclaration *&declarations) const
Retrieves all the declarations for a given IndexedQualifiedIdentifier in an efficient way...
Definition: persistentsymboltable.cpp:391
QualifiedIdentifier qualifiedIdentifier() const
Determine the global qualified identifier of this declaration.
Definition: declaration.cpp:267
uint topContextIndex() const
Definition: indexeddeclaration.h:88
virtual Declaration * specialize(const IndexedInstantiationInformation &specialization, const TopDUContext *topContext, int upDistance=0)
Retrieve the declaration which is specialized with the given specialization index as seen from topCon...
Definition: declaration.cpp:259
QualifiedIdentifier qualifiedIdentifier() const
Return the qualified identifier for this declaration.
Definition: declarationid.cpp:217
KDEVPLATFORMLANGUAGE_EXPORT DECLARE_LIST_MEMBER_HASH(InstantiationInformation, templateParameters, IndexedType) class KDEVPLATFORMLANGUAGE_EXPORT IndexedInstantiationInformation IndexedInstantiationInformation(uint index)
ConvenientEmbeddedSetTreeFilterIterator< IndexedDeclaration, IndexedDeclarationHandler, IndexedTopDUContext, CachedIndexedRecursiveImports, DeclarationTopContextExtractor > FilteredDeclarationIterator
Definition: persistentsymboltable.h:142
This file is part of the KDE documentation.
Documentation copyright © 1996-2019 The KDE developers.
Generated on Mon Dec 9 2019 02:48:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2019 The KDE developers.
Generated on Mon Dec 9 2019 02:48:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.