3 Copyright (c) Jeremy Siek 2000
5 Distributed under the Boost Software License, Version 1.0.
6 (See accompanying file LICENSE_1_0.txt or copy at
7 http://www.boost.org/LICENSE_1_0.txt)
10 <Title>MutablePropertyGraph
</Title>
11 <BODY BGCOLOR=
"#ffffff" LINK=
"#0000ee" TEXT=
"#000000" VLINK=
"#551a8b"
13 <IMG SRC=
"../../../boost.png"
14 ALT=
"C++ Boost" width=
"277" height=
"86">
21 <A NAME=
"sec:MutablePropertyGraph"></A>
25 A MutablePropertyGraph is a
<a
26 href=
"./MutableGraph.html">MutableGraph
</a> with properties attached
27 internally to the vertices and edges. When adding vertices and edges
28 the value of the properties can be given.
31 <H3>Refinement of
</H3>
33 <a href=
"./MutableGraph.html">MutableGraph
</a> and
34 <a href=
"./PropertyGraph.html">PropertyGraph
</a>
43 <TD>A type that is a model of Graph.
</TD>
48 <TD>An object of type
<tt>G
</tt>.
</TD>
53 <TD>An object of type
<tt>boost::graph_traits
<G
>::edge_descriptor
</tt>.
</TD>
58 <TD>are objects of type
<tt>boost::graph_traits
<G
>::vertex_descriptor
</tt>.
</TD>
62 <TD><TT>ep
</TT></TD><TD>is an object of type
<TT>G::edge_property_type
</TT></TD>
66 <TD><TT>vp
</TT></TD><TD>is an object of type
<TT>G::vertex_property_type
</TT></TD>
73 <H3>Associated Types
</H3>
78 <td>Edge Property Type
</td>
79 <td><TT>graph_traits
<G
>::edge_property_type
</TT></td>
83 <td>Vertex Property Type
</td>
84 <td><TT>graph_traits
<G
>::vertex_property_type
</TT> </td>
89 <H3>Valid Expressions
</h3>
94 <TD><TT>add_edge(u,
v,
ep,
g)
</TT></TD>
95 <TD>Inserts the edge
<i>(u,v)
</i> into the graph, and
96 copies object
<TT>ep
</TT> into the property for that edge.
<br>
97 Return type:
<TT>std::pair
<edge_descriptor, bool
></TT></TD>
101 <TD><TT>add_vertex(vp,
g)
</TT></TD>
103 Add a new vertex to the graph and copy
<TT>vp
</TT> into the
104 property for the new vertex. The
<TT>vertex_descriptor
</TT> for the new
105 vertex is returned.
<br>
106 Return type:
<TT>vertex_descriptor
</TT>
116 <LI><TT>adjacency_list
</TT></LI>
119 <H3>Concept Checking Class
</H3>
123 template
<class G
>
124 struct MutablePropertyGraphConcept
126 typedef typename boost::graph_traits
<G
>::edge_descriptor edge_descriptor;
128 BOOST_CONCEPT_ASSERT(( MutableGraphConcept
<G
> ));
129 v = add_vertex(vp, g);
130 p = add_edge(u, v, ep, g);
133 std::pair
<edge_descriptor, bool
> p;
134 typename boost::graph_traits
<G
>::vertex_descriptor u, v;
135 typename boost::graph_traits
<G
>::vertex_property_type vp;
136 typename boost::graph_traits
<G
>::edge_property_type ep;
145 <TD nowrap
>Copyright
© 2000-
2001</TD><TD>
146 <A HREF=
"http://www.boost.org/people/jeremy_siek.htm">Jeremy Siek
</A>, Indiana University (
<A HREF=
"mailto:jsiek@osl.iu.edu">jsiek@osl.iu.edu
</A>)