Boost logo

Boost Users :

From: Robert Kubrick (robertkubrick_at_[hidden])
Date: 2008-08-16 11:37:15


A couple of beginner questions on basic_managed_heap_memory:

1) I want to access elements in the contiguous memory segment by
using an int key, rather than a char string. Can I declare something
like this:

typedef basic_managed_heap_memory <
    int, /* my key is an integer */
    rbtree_best_fit<null_mutex_family>,
    flat_map_index
> managed_heap_memory;

I need to lookup objects using an external integer ID but the ID can
have any value (ie, does not match the 0-N array element order of my
memory segment).

2) If I want to insert multiple objects with the same char* name (ala
multimap) can I create a flat_multimap_index?



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