Obtaining Microsoft Exchange Server Interfaces

Many of the programming tasks that manipulate information store data rely on the use of Microsoft Exchange Server interfaces. Most of these interfaces are available through the extensibility mechanism that MAPI provides for objects.

This mechanism is the support MAPI provides for properties that are themselves objects. These object properties have the type PT_OBJECT and implement the IUnknown interface. For properties of this type, call the IMAPIProp::OpenProperty method instead of GetProps. As indicated in the following table, you need to pass the correct value in the lpiid parameter to obtain the correct interface.

In some cases, you obtain an interface pointer by calling a function designed to return that pointer, such as HrFolderACLsOpen.

The following table lists the interfaces provided by Microsoft Exchange Server and the actions you take to obtain a pointer to each.

Microsoft Exchange Server Interfaces

Interface To obtain a pointer to this interface
IExchangeExportChanges The controlling process (agent) must open the store and call the MAPI IMAPIProp::OpenProperty method on either the PR_CONTENTS_SYNCHRONIZER property (to synchronize the contents of a folder) or the PR_HIERARCHY_SYNCHRONIZER property (to synchronize the hierarchy of a folder). When calling the OpenProperty method, pass the value IID_IExchangeExportChanges in the lpiid parameter.
IExchangeFavorites Call the MAPI IMAPIProp::GetProps method with the PR_IPM_FAVORITES_ENTRYID property and then the MAPI IMsgStore::OpenEntry method with that entry identifier. When calling the OpenEntry method, pass the value IID_IExchangeFavorites in the lpInterface parameter.
IExchangeFolderACLs Call the HrFolderACLsOpen function.
IExchangeFolderRules Call the HrFolderRulesOpen function.
IExchangeImportContentsChanges The controlling process (agent) must open the store and call the MAPI IMAPIProp::OpenProperty method on the PR_COLLECTOR property of the object. When calling the OpenProperty method, pass the value IID_IExchangeImportContentsChanges in the lpiid parameter.
IExchangeImportHierarchyChanges The controlling process (agent) must open the store and call the MAPI IMAPIProp::OpenProperty method on the PR_COLLECTOR property of the object. When calling the OpenProperty method, pass the value IID_IExchangeImportHierarchyChanges in the lpiid parameter.
IExchangeManageStore Call the QueryInterface method of the information store object.
IExchangeModifyTable Call the MAPI IMAPIProp::OpenProperty method on any property of type PT_OBJECT. When calling the OpenProperty method, pass the value IID_IExchangeModifyTable in the lpiid parameter.
IExchangeRuleAction Call the MAPI IMAPIProp::OpenProperty method on the PR_CLIENT_ACTIONS property of the object. When calling the OpenProperty method, pass the value IID_IExchangeRuleAction in the lpiid parameter.

For more information, see Microsoft Exchange Server Interfaces.