The library
class has an associated iterator class.
In the language of the Standard Template Library, this is an input iterator. This means that you may only use it to read methods from the library in order, starting at the beginning. The value type of the iterator is
library_entry
see The library_entry class.
These functions return iterators pointing to the beginning and end of the library, respectively.
This is how these functions may be used to iterate through the library:
// Open a library library l("my_library.xml"); library::const_iterator i; // Print the base name of each method in it for(i = l.begin(); i != l.end(); ++i) cout << i->base_name() << endl;