ITypeInfo Interface

This section describes ITypeInfo, an interface typically used for reading information about objects. For example, an object browser tool can use ITypeInfo to extract information about the characteristics and capabilities of objects from type libraries.

Implemented by

Used by

Header file name

Oleaut32.dll (32-bit systems) Typelib.dll (16-bit systems)

Tools that need to access the descriptions of objects contained in type libraries.

Oleauto.h Dispatch.h

Type information interfaces are intended to describe the parts of the application that can be called by outside clients, rather than those that might be used internally to build an application.

The ITypeInfo interface provides access to the following:

  • The set of function descriptions associated with the type. For interfaces, this contains the set of member functions in the interface.

  • The set of data member descriptions associated with the type. For structures, this contains the set of fields of the type.

  • The general attributes of the type, such as whether it describes a structure, an interface, and so on.

The type description of an IDispatch interface can be used to implement the interface. For more information, see the description of CreateStdDispatch in Dispatch Interface and API Functions.

An instance of ITypeInfo provides various information about the type of an object, and is used in different ways. A compiler can use an ITypeInfo to compile references to members of the type. A type interface browser can use it to find information about each member of the type. An IDispatch implementor can use it to provide automatic delegation of IDispatch calls to an interface.