]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | <HTML> |
2 | <!-- | |
3 | Copyright (c) Jeremy Siek, Lie-Quan Lee, and Andrew Lumsdaine 2000 | |
4 | ||
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) | |
8 | --> | |
9 | <Head> | |
10 | <Title>Boost Graph Library: Visitor Concepts</Title> | |
11 | <BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b" | |
12 | ALINK="#ff0000"> | |
13 | <IMG SRC="../../../boost.png" | |
14 | ALT="C++ Boost" width="277" height="86"> | |
15 | ||
16 | <BR Clear> | |
17 | ||
18 | <H1><A NAME="sec:visitor-concepts"></A> | |
19 | Visitor Concepts | |
20 | </H1> | |
21 | ||
22 | <P> | |
23 | The visitor concepts plays the same role in BGL as <a | |
24 | href="http://www.sgi.com/tech/stl/functors.html">functors</a> | |
25 | play in the STL. Functors provide a mechanism for extending an | |
26 | algorithm; for customizing what is done at each step of the algorithm. | |
27 | Visitors allow the user to insert their own operations at various | |
28 | steps within a graph algorithm. Unlike the STL algorithms, graph | |
29 | algorithms typically have multiple event points where one may want to | |
30 | insert a call-back via a functor. Therefore visitors do not have a | |
31 | single <tt>operator()</tt> method like a functor, but instead have | |
32 | several methods that correspond to the various event points. Each | |
33 | algorithm has a different set of event points, which are described by | |
34 | the following visitor concepts: | |
35 | ||
36 | <ul> | |
37 | <li> <a href="./BFSVisitor.html">BFS Visitor</a> | |
38 | <li> <a href="./DFSVisitor.html">DFS Visitor</a> | |
39 | <li> <a href="./DijkstraVisitor.html">Dijkstra Visitor</a> | |
40 | <li> <a href="./BellmanFordVisitor.html">Bellman Ford Visitor</a> | |
41 | <li> <a href="./AStarVisitor.html">A* Visitor</a> | |
42 | <li> <a href="./EventVisitor.html">Event Visitor</a> | |
43 | <li> <a href="./PlanarFaceVisitor.html">Planar Face Visitor</a> | |
44 | <li> <a href="./TSPTourVisitor.html">TSP Tour Visitor</a> | |
45 | </ul> | |
46 | ||
47 | ||
48 | <br> | |
49 | <HR> | |
50 | <TABLE> | |
51 | <TR valign=top> | |
52 | <TD nowrap>Copyright © 2000-2001</TD><TD> | |
53 | <A HREF="http://www.boost.org/people/jeremy_siek.htm">Jeremy Siek</A>, | |
54 | Indiana University (<A | |
55 | HREF="mailto:jsiek@osl.iu.edu">jsiek@osl.iu.edu</A>)<br> | |
56 | <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> | |
57 | <A HREF="http://www.osl.iu.edu/~lums">Andrew Lumsdaine</A>, | |
58 | Indiana University (<A | |
59 | HREF="mailto:lums@osl.iu.edu">lums@osl.iu.edu</A>) | |
60 | </TD></TR></TABLE> | |
61 | ||
62 | </BODY> | |
63 | </HTML> |