PropertyTag.html 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. <HTML>
  2. <!--
  3. Copyright (c) Jeremy Siek 2000
  4. Distributed under the Boost Software License, Version 1.0.
  5. (See accompanying file LICENSE_1_0.txt or copy at
  6. http://www.boost.org/LICENSE_1_0.txt)
  7. -->
  8. <Head>
  9. <Title>Property</Title>
  10. <BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b"
  11. ALINK="#ff0000">
  12. <IMG SRC="../../../boost.png"
  13. ALT="C++ Boost" width="277" height="86">
  14. <BR Clear>
  15. <H2><A NAME="concept:PropertyTag"></A>
  16. PropertyTag
  17. </H2>
  18. A Property Tag is a type used to name or identify properties that are
  19. attached to the vertices and edges of a graph. A Property type is not
  20. the type of the actual property values. Objects of the Property type
  21. are not used except to carry the type information which specifies the
  22. property. See the section about <A
  23. href="using_adjacency_list.html#sec:custom-edge-properties"> Custom
  24. Edge Properties</a> for a description of how to define your own
  25. property tags.
  26. <h3>Associated Types</h3>
  27. <table border>
  28. <tr>
  29. <td>Property Kind </td>
  30. <td><TT>property_kind&lt;PropertyTag&gt;::type</TT> </td>
  31. <td>
  32. This specifies whether the property is a <a
  33. name="VertexPropertyTag"><b>Vertex Property Tag</b></a>
  34. (<tt>vertex_property_tag</tt>), an <a
  35. name="EdgePropertyTag"><b>Edge Property Tag</b></a> (<tt>edge_property_tag</tt>), or
  36. a <a name="GraphPropertyTag"><b>Graph Property Tag</b></a> which is attached to the
  37. graph object itself (<tt>graph_property_tag</tt>). The tags are
  38. defined in <a
  39. href="../../../boost/graph/properties.hpp"><tt>boost/graph/properties.hpp</tt></a>. The <tt>property_kind</tt> traits class is defined in <a href="../../../boost/pending/property.hpp"><tt>boost/pending/property.hpp</tt></a>.
  40. </td>
  41. </tr>
  42. <tr>
  43. <td>Property ID Number </td>
  44. <td><TT>property_num&lt;PropertyTag&gt;::value</TT> </td>
  45. <td>
  46. This is needed as a workaround when using compilers that do not
  47. support partial specialization (and hence prevent us from using
  48. <tt>boost::is_same</tt> to detect if two property tags are the same).
  49. The <tt>property_num</tt> traits class is defined in <a
  50. href="../../../boost/pending/property.hpp"><tt>boost/pending/property.hpp</tt></a>.
  51. </td>
  52. </tr>
  53. </table>
  54. <h3>Refinement of</h3>
  55. <a
  56. href="http://www.boost.org/sgi/stl/DefaultConstructible.html">Default Constructible</a>
  57. <h3>Models</h3>
  58. The following models of the Property Tag concept are defined
  59. in <a
  60. href="../../../boost/graph/properties.hpp"><tt>boost/graph/properties.hpp</tt></a>.
  61. <ul>
  62. <li><tt>vertex_index_t</tt></li>
  63. <li><tt>edge_index_t</tt></li>
  64. <li><tt>graph_name_t</tt></li>
  65. <li><tt>vertex_name_t</tt></li>
  66. <li><tt>edge_name_t</tt></li>
  67. <li><tt>edge_weight_t</tt></li>
  68. <li><tt>vertex_distance_t</tt></li>
  69. <li><tt>vertex_color_t</tt></li>
  70. <li><tt>vertex_degree_t</tt></li>
  71. <li><tt>vertex_out_degree_t</tt></li>
  72. <li><tt>vertex_in_degree_t</tt></li>
  73. <li><tt>vertex_discover_time_t</tt></li>
  74. <li><tt>vertex_finish_time_t</tt></li>
  75. </ul>
  76. <h3>See Also</h3>
  77. <a href="./PropertyGraph.html">PropertyGraph</a>
  78. and
  79. <a href="../../property_map/doc/property_map.html">Property Map Concepts</a>
  80. <h3>Notes</h3>
  81. On compilers that do not support partial specialization, each Property
  82. type is also required to specialize
  83. <tt>property_num&lt;PropertyTag&gt;</tt> to contain an enum named
  84. <tt>value</tt> which uniquely identifies the property type.
  85. <br>
  86. <HR>
  87. <TABLE>
  88. <TR valign=top>
  89. <TD nowrap>Copyright &copy; 2000-2001</TD><TD>
  90. <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>)
  91. </TD></TR></TABLE>
  92. </BODY>
  93. </HTML>