Share via


IDeclarations Interface

Returns the completion set information needed to populate an IntelliSense completion list.

IDeclarations : IDispatch

Methods in Vtable Order

The following table shows the methods of this interface.

Method

Description

IDeclarations::GetCount Method

Returns the number of declarations in the completion list.

IDeclarations::GetName Method

Returns the name of an item in the completion list, based on the index position specified.

IDeclarations::GetDescription Method

Returns the quick info tip information shown when a user selects a language item in the completion list, such as a method name.

IDeclarations::GetGlyph Method

Returns the icon of an item in the completion list.

IDeclarations::GetBestMatch Method

Returns the index position of the best match for a string of text.

Remarks

This interface is an abstraction of the IntelliSense completion list feature in Visual Studio. In a more general case, this interface is an abstraction of any list of declarations. A declaration is the name of a method, variable, property, function, class, or whatever can be declared in a language, often as part of an enclosing container such as a class or namespace. In addition, a declaration has associated with it a description and an icon (also known as a glyph). This declaration information is presented in an IntelliSense completion list.

For example, statement completion information is provided in Visual C++ when the user types "->" or, in Visual Basic or C#, when the user types ".". These are called member completion characters. Thus, when a user types a member completion character, Babel calls the IScope::GetDeclarations Method, which builds an IDeclarations object that contains all the members of a class or the group of global functions and variables. For more information about the Members list feature, see List Members in the MSDN Library.

Note

Typically, the IDeclarations object is created when the IScope::GetDeclarations Method is called and the object is populated from the results of the last full parse operation (with the parse reason ReasonCheck).

Notes for Implementers

Implement this interface to support returning a completion set from your implementation of the IScope::GetDeclarations Method. If you are The Default Babel Implementation in the Language Service Package, then there is no need to override or otherwise implement this interface.

Notes for Callers

Call the IScope::GetDeclarations Method to obtain an instance of this interface.

Requirements

Header: BabelService.idl

See Also

Concepts

The Default Babel Implementation in the Language Service Package

Reference

IScope::GetDeclarations Method

List Members