
Hello, ----- Mensaje original ----- De: Phantom <r...@phantom-web.co.uk> Fecha: Lunes, Agosto 29, 2005 7:59 pm Asunto: [Boost-users] Boost::multiIndex container problems
Hi,
I'm trying to use the boost::multi_index_container to index a struct based on a enum and a std::string. While I can retrive data from the container by search on the string any attempts to such on the enum results in a compliation error. Anyone got any ideas as to what I need todo to get this to work :)
I haven't compiled your code, but I think the problem lies in that you define the id index as mi::ordered_unique< mi::tag<id> , mi::identity<FilterCreatorDetails> > that is, the key for this index is the *whole* FilterCreatorDetails object; yet, you later try to use it passing a FileTypes value. Try defining your index as: mi::ordered_unique< mi::tag<id> , mi::member< FilterCreatorDetails,FileTypes, &FilterCreatorDetails::id_> > and I think everything should work. Please come back here if it doesn't. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo