Boost logo

Boost :

Subject: Re: [boost] [bgl] Reconnecting an edge
From: Andrew Sutton (andrew.n.sutton_at_[hidden])
Date: 2010-04-01 11:32:50


> Is there any way to reconnect an edge in a graph? I'm interested in
>> doing so while retaining a property map. Thus remove_edge and add_edge
>> are not a solution, I think. If not, may it worth to add such a concept?
>>
>
> I do not believe there is a way to do that other than by messing with
> internal data structures. Is copying the properties over too slow for what
> you're doing? If the properties are large/slow to copy, would having a
> shared_ptr as the property stored in the graph help?
>

I wrote an algorithm a couple years ago that did something similar -
conceptually temporarily removing and re-adding edges. Rather than modify
the actual graph, I just used a color map to mask the edges that were
temporarily being excluded.

Would that be an option for your application?

Andrew Sutton
andrew.n.sutton_at_[hidden]


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk