model_server/subsystem/src/Entity.cxx
//=============================================
// collect_classes_from_type: takes the type ("has_type" link) of the
// supplied symbol and filters the result for a class or enum that is
// used in the type.  It handles indirecting through typedefs.  If the
// result array is non-empty, it returns "true."
//=============================================
takes the type ("has_type" link) of the
supplied symbol and filters the result for a class or enum that is
used in the type.  It handles indirecting through typedefs.  If the
result array is non-empty, it returns "true."
takes the type ( " has_type " link ) of the supplied symbol and filters the result for a class or enum that is used in the type . It handles indirecting through typedefs . If the result array is non - empty it returns " true . "
bool collect_classes_from_type(const symbolPtr& type, symbolArr& classes,
			       const objSet& projects_to_search) {
   Initialize(collect_classes_from_type);
   symbolArr targs;
   if (type->get_link(is_using, targs, projects_to_search, type.get_xref()->get_lxref())) {
      symbolPtr targ;
      ForEachS(targ, targs) {
	 ddKind k = targ.get_kind();
	 if (k == DD_CLASS || k == DD_ENUM) {
	    classes.insert_last(targ);
	 }
	 else if (k == DD_TYPEDEF) {
	    symbolArr targs2;
	    if (targ.get_link(have_arg_type, targs2,
			       projects_to_search)) {
	       symbolPtr targ2;
	       ForEachS(targ2, targs2) {
		  ddKind k2 = targ2.get_kind();
		  if (k2 == DD_CLASS || k2 == DD_ENUM) {
		     classes.insert_last(targ2);
		  }
	       }
	    }
	 }
      }
   }
   return (classes.size() > 0);
}
bool collect_classes_from_type ( const symbolPtr & type , symbolArr & classes , const objSet & projects_to_search ) { Initialize ( collect_classes_from_type ) ; symbolArr targs ; if ( type -> get_link ( is_using , targs , projects_to_search , type . get_xref ( ) -> get_lxref ( ) ) ) { symbolPtr targ ; ForEachS ( targ , targs ) { ddKind k = targ . get_kind ( ) ; if ( k == DD_CLASS || k == DD_ENUM ) { classes . insert_last ( targ ) ; } else if ( k == DD_TYPEDEF ) { symbolArr targs2 ; if ( targ . get_link ( have_arg_type , targs2 , projects_to_search ) ) { symbolPtr targ2 ; ForEachS ( targ2 , targs2 ) { ddKind k2 = targ2 . get_kind ( ) ; if ( k2 == DD_CLASS || k2 == DD_ENUM ) { classes . insert_last ( targ2 ) ; } } } } } } return ( classes . size ( ) > 0 ) ; }
collect_classes_from_type: takes the type ("has_type" link) of the
supplied symbol and filters the result for a class or enum that is
used in the type.
collect_classes_from_type : takes the type ( " has_type " link ) of the supplied symbol and filters the result for a class or enum that is used in the type .