Поделиться через


CDumpContext::SetDepth

Sets the depth for the dump.

void SetDepth(
   int nNewDepth 
);

Параметры

  • nNewDepth
    The new depth value.

Заметки

If you are dumping a primitive type or simple CObject that contains no pointers to other objects, then a value of 0 is sufficient. A value greater than 0 specifies a deep dump where all objects are dumped recursively. For example, a deep dump of a collection will dump all elements of the collection. You may use other specific depth values in your derived classes.

ПримечаниеПримечание.

Circular references are not detected in deep dumps and can result in infinite loops.

Пример

#if _DEBUG
   afxDump.SetDepth(1);  // Specifies deep dump
   ASSERT(afxDump.GetDepth() == 1);      
#endif

Требования

Header: afx.h

См. также

Основные понятия

CDumpContext Class

CDumpContext Members

Hierarchy Chart

CObject::Dump