I would recommend taking advantage of the data structures offered by the STL. Specifically, I would store the 'object database' as an STL map, with a string representing the object's name as the key, and a pointer to the object as the value. Using a map would make the three operations you listed fairly trivial.