BOOL IsKindOf( const CRuntimeClass* pClass ) const;
pClass
A pointer to a CRuntimeClass structure associated with your CObject-derived class.
IsKindOf tests this object to see if (1) it is an object of the specified class or (2) if it is an object of a class derived from the specified class. This function only works for classes declared with the DECLARE_DYNAMIC or DECLARE_SERIAL macros.
Do not use this function extensively because it defeats the C++ polymorphism feature. Use virtual functions instead.
TRUE if the object corresponds to the class; otherwise FALSE.
CAge a(21); // must use IMPLEMENT_DYNAMIC or IMPLEMENT_SERIAL
ASSERT( a.IsKindOf( RUNTIME_CLASS( CAge ) ) );