clang API Documentation
The context in which code completion occurred, so that the code-completion consumer can process the results accordingly. More...
#include <CodeCompleteConsumer.h>
Public Types | |
enum | Kind { CCC_Other, CCC_OtherWithMacros, CCC_TopLevel, CCC_ObjCInterface, CCC_ObjCImplementation, CCC_ObjCIvarList, CCC_ClassStructUnion, CCC_Statement, CCC_Expression, CCC_ObjCMessageReceiver, CCC_DotMemberAccess, CCC_ArrowMemberAccess, CCC_ObjCPropertyAccess, CCC_EnumTag, CCC_UnionTag, CCC_ClassOrStructTag, CCC_ObjCProtocolName, CCC_Namespace, CCC_Type, CCC_Name, CCC_PotentiallyQualifiedName, CCC_MacroName, CCC_MacroNameUse, CCC_PreprocessorExpression, CCC_PreprocessorDirective, CCC_NaturalLanguage, CCC_SelectorName, CCC_TypeQualifiers, CCC_ParenthesizedExpression, CCC_ObjCInstanceMessage, CCC_ObjCClassMessage, CCC_ObjCInterfaceName, CCC_ObjCCategoryName, CCC_Recovery } |
Public Member Functions | |
CodeCompletionContext (enum Kind Kind) | |
Construct a new code-completion context of the given kind. | |
CodeCompletionContext (enum Kind Kind, QualType T, ArrayRef< IdentifierInfo * > SelIdents=None) | |
Construct a new code-completion context of the given kind. | |
enum Kind | getKind () const |
Retrieve the kind of code-completion context. | |
QualType | getPreferredType () const |
Retrieve the type that this expression would prefer to have, e.g., if the expression is a variable initializer or a function argument, the type of the corresponding variable or function parameter. | |
QualType | getBaseType () const |
Retrieve the type of the base object in a member-access expression. | |
ArrayRef< IdentifierInfo * > | getSelIdents () const |
Retrieve the Objective-C selector identifiers. | |
bool | wantConstructorResults () const |
Determines whether we want C++ constructors as results within this context. |
The context in which code completion occurred, so that the code-completion consumer can process the results accordingly.
Definition at line 153 of file CodeCompleteConsumer.h.
Definition at line 155 of file CodeCompleteConsumer.h.
clang::CodeCompletionContext::CodeCompletionContext | ( | enum Kind | Kind | ) | [inline] |
Construct a new code-completion context of the given kind.
Definition at line 278 of file CodeCompleteConsumer.h.
clang::CodeCompletionContext::CodeCompletionContext | ( | enum Kind | Kind, |
QualType | T, | ||
ArrayRef< IdentifierInfo * > | SelIdents = None |
||
) | [inline] |
Construct a new code-completion context of the given kind.
Definition at line 281 of file CodeCompleteConsumer.h.
References CCC_ArrowMemberAccess, CCC_DotMemberAccess, CCC_ObjCClassMessage, CCC_ObjCInstanceMessage, and CCC_ObjCPropertyAccess.
QualType clang::CodeCompletionContext::getBaseType | ( | ) | const [inline] |
Retrieve the type of the base object in a member-access expression.
Definition at line 303 of file CodeCompleteConsumer.h.
enum Kind clang::CodeCompletionContext::getKind | ( | ) | const [inline] |
Retrieve the kind of code-completion context.
Definition at line 294 of file CodeCompleteConsumer.h.
Referenced by CalculateHiddenNames().
QualType clang::CodeCompletionContext::getPreferredType | ( | ) | const [inline] |
Retrieve the type that this expression would prefer to have, e.g., if the expression is a variable initializer or a function argument, the type of the corresponding variable or function parameter.
Definition at line 299 of file CodeCompleteConsumer.h.
ArrayRef<IdentifierInfo *> clang::CodeCompletionContext::getSelIdents | ( | ) | const [inline] |
Retrieve the Objective-C selector identifiers.
Definition at line 306 of file CodeCompleteConsumer.h.
Determines whether we want C++ constructors as results within this context.
Definition at line 34 of file CodeCompleteConsumer.cpp.
References CCC_ArrowMemberAccess, CCC_ClassOrStructTag, CCC_ClassStructUnion, CCC_DotMemberAccess, CCC_EnumTag, CCC_Expression, CCC_MacroName, CCC_MacroNameUse, CCC_Name, CCC_Namespace, CCC_NaturalLanguage, CCC_ObjCCategoryName, CCC_ObjCClassMessage, CCC_ObjCImplementation, CCC_ObjCInstanceMessage, CCC_ObjCInterface, CCC_ObjCInterfaceName, CCC_ObjCIvarList, CCC_ObjCMessageReceiver, CCC_ObjCPropertyAccess, CCC_ObjCProtocolName, CCC_Other, CCC_OtherWithMacros, CCC_ParenthesizedExpression, CCC_PotentiallyQualifiedName, CCC_PreprocessorDirective, CCC_PreprocessorExpression, CCC_Recovery, CCC_SelectorName, CCC_Statement, CCC_TopLevel, CCC_Type, CCC_TypeQualifiers, and CCC_UnionTag.