Interface IIndexBinding
-
- All Superinterfaces:
org.eclipse.core.runtime.IAdaptable
,IBinding
- All Known Subinterfaces:
IIndexMacro
,IIndexMacroContainer
public interface IIndexBinding extends IBinding
Represents the semantics of a name in the index.- Since:
- 4.0
- Restriction:
- This interface is not intended to be implemented by clients.
- Restriction:
- This interface is not intended to be extended by clients.
-
-
Field Summary
Fields Modifier and Type Field Description static IIndexBinding[]
EMPTY_INDEX_BINDING_ARRAY
-
Fields inherited from interface org.eclipse.cdt.core.dom.ast.IBinding
EMPTY_BINDING_ARRAY
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IIndexFile
getLocalToFile()
Returns the file this binding is local to, ornull
for global bindings.IIndexBinding
getOwner()
Returns the binding that owns this binding, ornull
if there is no owner.String[]
getQualifiedName()
Returns the qualified name of this binding as array of strings.boolean
isFileLocal()
Returns whether the scope of the binding is file-local.-
Methods inherited from interface org.eclipse.cdt.core.dom.ast.IBinding
getLinkage, getName, getNameCharArray, getScope
-
-
-
-
Field Detail
-
EMPTY_INDEX_BINDING_ARRAY
static final IIndexBinding[] EMPTY_INDEX_BINDING_ARRAY
-
-
Method Detail
-
getQualifiedName
String[] getQualifiedName()
Returns the qualified name of this binding as array of strings.
-
isFileLocal
boolean isFileLocal() throws org.eclipse.core.runtime.CoreException
Returns whether the scope of the binding is file-local. A file local binding is private to an index and should not be adapted to a binding in another index.- Throws:
org.eclipse.core.runtime.CoreException
-
getLocalToFile
IIndexFile getLocalToFile() throws org.eclipse.core.runtime.CoreException
Returns the file this binding is local to, ornull
for global bindings. A binding is local if a file has a separate instances of the binding. This is used to model static files, static variables.- Throws:
org.eclipse.core.runtime.CoreException
-
getOwner
IIndexBinding getOwner()
Description copied from interface:IBinding
Returns the binding that owns this binding, ornull
if there is no owner.The owner is determined as follows:
ICPPUsingDeclaration
: The owner depends on where the declaration is found, within a function or method, a class-type, a namespace or on global scope.
ICPPTemplateParameter
: The owner is theICPPTemplateDefinition
.
IEnumerator
: The owner is theIEnumeration
, independent of whether they are scoped or not.
For all other bindings: The owner depends on where the binding can be defined (it could be declared elsewhere).Possible owners are:
IFunction
: for parameters, local types, variables, enumerators, labels and using declarations;
Closure represented byICPPClassType
: for lambda expression parameters;
ICPPClassType
: for class-, struct- and union-members, even if the composite type is anonymous; also for enumerators and using declarations;
ICompositeType
: for struct- and union-members, even if the composite type is anonymous; also for anonymous structs or unions found within another struct;
ICPPNamespace
: for global types, functions, variables, enumerators, namespaces and using declarations;
IEnumeration
: for enumerators.
null
: for types, functions, variables, namespaces and using declarations;
-
-