The Boost Multi-Index Containers Library
By Joaquin Ma Lopez Munoz, September 01, 2004
The Boost Multi-index Containers Library is a framework that provides-according to your specification-multiple, distinct interfaces to a single underlying container.
September, 2004: The Boost Multi-Index Containers Library
Listing 5
company cmp;
...
cmp.get<1>().insert(employee(284, "Calvin Smith", 32));
// the following insertion will fail;
// returns a pair<iterator,bool> where the second member is set to false
cmp.get<1>().insert(employee(284, "Robert Garcia", 40));