Last modified: October 12, 2010
Applies to: Office 2010 | Outlook 2010 | Visual Studio
Returns a pointer to the container's hierarchy table.
The IMAPIContainer::GetHierarchyTable method returns a pointer to the hierarchy table of a container. A hierarchy table holds summary information about the child containers in the container. Folder hierarchy tables hold information about subfolders; address book hierarchy tables hold information about child address book containers and distribution lists.
It is possible for some containers to have no child containers. These containers return MAPI_E_NO_SUPPORT from their implementations of GetHierarchyTable.
When the CONVENIENT_DEPTH flag is set, each row in the hierarchy table also includes the PR_DEPTH (PidTagDepth) property as a column. PR_DEPTH indicates the level of each container relative to the container that implements the table. The implementing container's immediate child containers are at depth zero, child containers in the zero depth containers are at depth one, and so on. The values of PR_DEPTH increase sequentially as the hierarchy of levels deepens.
For a complete list of required and optional columns in hierarchy tables, see Hierarchy Tables.
If you support a hierarchy table for your container, you must also do the following:
String and binary contents table columns can be truncated. Typically, providers return 255 characters. Because you cannot know beforehand whether a table includes truncated columns, assume that a column is truncated if the length of the column is either 255 or 510 bytes. You can always retrieve the full value of a truncated column, if necessary, directly from the object by using its entry identifier to open it and then calling the IMAPIProp::GetProps method.
Depending on the provider's implementation, restrictions and sorting operations can apply to the whole string or to the truncated version of that string. Moreover, store providers are not guaranteed to honor the sort order set SSortOrderSet specified for hierarchy tables.