|
Boost Users : |
From: Aaron Windsor (aaron.windsor_at_[hidden])
Date: 2008-03-26 08:53:11
On Wed, Mar 26, 2008 at 6:16 AM, Hardik Kheskani
<hardik.kheskani_at_[hidden]> wrote:
>
>
>
> I am using adjacent lists and using vertex_descriptors.
> Is there a way to check if the vertex_descriptor is NULL or 'not assigned'
> yet?
>
> graph_traits < adjacent_list_graph >::vertex_descriptor vd ;
>
> can I assign this to NULL ?
> and can I use vd == NULL or vd != NULL ?
>
Hi Hardik,
graph_traits< adjacent_list_graph >::null_vertex() exists for just
this purpose - to represent a vertex descriptor that should never be
used as a valid vertex descriptor by the underlying graph.
Regards,
Aaron
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