- std::list<std::string> result;
- for(ItemMap::const_iterator i=items.begin(); i!=items.end(); ++i)
- if(i->second.check_type<RefPtr<typename RemoveConst<T>::Type> >())
- result.push_back(i->first);
- return result;
+ std::list<std::string> names;
+ gather_items<typename RemoveConst<T>::Type>(0, &names, 0, false);
+ return names;
+ }
+
+ /** Returns a list of the names of objects of one type in the collection or
+ available from sources. */
+ template<typename T>
+ std::list<std::string> get_names()
+ {
+ std::list<std::string> names;
+ gather_items<typename RemoveConst<T>::Type>(0, &names, 0, true);
+ return names;