Blame view

3rdparty/boost_1_81_0/libs/graph/doc/incident.html 2.09 KB
977ed18d   Hu Chunming   提交三方库
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
  <HTML>
  <!--
       Copyright (c) Jeremy Siek, Lie-Quan Lee, and Andrew Lumsdaine 2000
  
       Distributed under the Boost Software License, Version 1.0.
       (See accompanying file LICENSE_1_0.txt or copy at
       http://www.boost.org/LICENSE_1_0.txt)
    -->
  <Head>
  <Title>Boost Graph Library: incident</Title>
  <BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b"
          ALINK="#ff0000">
  <IMG SRC="../../../boost.png"
       ALT="C++ Boost" width="277" height="86">
  
  <BR Clear>
  
  <H1><A NAME="sec:incident"></A>
  <TT>incident</TT>
  </H1>
  
  <P>
  <DIV ALIGN="left">
  <TABLE CELLPADDING=3 border>
  
  <TR><TH ALIGN="LEFT"><B>Complexity:</B></TH>
  <TD ALIGN="LEFT"><i>O(1)</i>
  </TD>
  </TR>
  
  <TR><TH ALIGN="LEFT"><B>Where Defined:</B></TH>
  <TD ALIGN="LEFT">
  <a href="../../../boost/graph/graph_utility.hpp"><TT>boost/graph/graph_utility.hpp</TT></a>
  </TD>
  
  </TABLE>
  </DIV>
  
  <P>
  <PRE>
    template &lt;class Graph&gt;
    std::pair&lt;typename graph_traits&lt;Graph&gt;::vertex_descriptor,
              typename graph_traits&lt;Graph&gt;::vertex_descriptor&gt;
    incident(typename graph_traits&lt;Graph&gt;::edge_descriptor e, Graph& g)
  </pre>
  
  This function takes an edge descriptor and returns the pair of
  vertices that are <i>incident</i> to the edge. For directed graphs,
  the <tt>first</tt> vertex is the source and the <tt>second</tt> vertex
  is the target. This function is equivalent to the expression
  <tt>std::make_pair(source(e, g), target(e, g))</tt>.
  
  
  <h3>Example</h3>
  
  <pre>
    edge_descriptor e;
    vertex_descriptor u, v;
    ...
    boost::tie(u, v) = incident(e, g);
  </pre>
  
  
  <br>
  <HR>
  <TABLE>
  <TR valign=top>
  <TD nowrap>Copyright &copy; 2000-2001</TD><TD>
  <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>)<br>
  <A HREF="http://www.boost.org/people/liequan_lee.htm">Lie-Quan Lee</A>, Indiana University (<A HREF="mailto:llee@cs.indiana.edu">llee@cs.indiana.edu</A>)<br>
  <A HREF="https://homes.cs.washington.edu/~al75">Andrew Lumsdaine</A>,
  Indiana University (<A
  HREF="mailto:lums@osl.iu.edu">lums@osl.iu.edu</A>)
  </TD></TR></TABLE>
  
  </BODY>
  </HTML>