|
Boost Users : |
From: boost_at_[hidden]
Date: 2007-06-29 06:12:10
On Fri, Jun 29, 2007 at 07:05:56AM -0300, Felipe Magno de Almeida wrote:
> On 6/29/07, boost_at_[hidden] <boost_at_[hidden]> wrote:
> > Hello
> >
> > I'm trying to use multi_index with an ordered_non_unique index. My
> > question is how can I perform a search like with "find(key)" and get all
> > the elements that match that key. Since find only returns one element
> > that match, and there can be several in the container.
>
> Use equal_range. It returns a pair of iterators to begin and end of
> the equal range.
>
> >
> > I've tried to iterate "count(key)" times with the iterator returned by
> > find but doesn't seem to work. Is there a way to do this?
> >
> > Regards
> >
> > --
> > Pedro Larroy Tovar, pedro at larroy dot com | http://pedro.larroy.com/
> > * Las patentes de programación son nocivas para la innovación *
> > http://proinnova.hispalinux.es/
>
> Best regards,
> --
> Felipe Magno de Almeida
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
Thanks! I didn't noticed that function.
-- Pedro Larroy Tovar, pedro at larroy dot com | http://pedro.larroy.com/ * Las patentes de programación son nocivas para la innovación * http://proinnova.hispalinux.es/
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net