mirror of
https://github.com/boostorg/graph.git
synced 2026-01-29 19:42:11 +00:00
65 lines
2.4 KiB
HTML
65 lines
2.4 KiB
HTML
<HTML>
|
|
<!--
|
|
-- Copyright (c) Jeremy Siek, Lie-Quan Lee, and Andrew Lumsdaine 2000
|
|
--
|
|
-- Permission to use, copy, modify, distribute and sell this software
|
|
-- and its documentation for any purpose is hereby granted without fee,
|
|
-- provided that the above copyright notice appears in all copies and
|
|
-- that both that copyright notice and this permission notice appear
|
|
-- in supporting documentation. We make no
|
|
-- representations about the suitability of this software for any
|
|
-- purpose. It is provided "as is" without express or implied warranty.
|
|
-->
|
|
<Head>
|
|
<Title>Boost Graph Library: Visitor Concepts</Title>
|
|
<BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b"
|
|
ALINK="#ff0000">
|
|
<IMG SRC="../../../c++boost.gif"
|
|
ALT="C++ Boost" width="277" height="86">
|
|
|
|
<BR Clear>
|
|
|
|
<H1><A NAME="sec:visitor-concepts"></A>
|
|
Visitor Concepts
|
|
</H1>
|
|
|
|
<P>
|
|
The visitor concepts plays the same role in BGL as <a
|
|
href="http://www.sgi.com/tech/stl/functors.html">functors</a>
|
|
play in the STL. Functors provide a mechanism for extending an
|
|
algorithm; for customizing what is done at each step of the algorithm.
|
|
Visitors allow the user to insert their own operations at various
|
|
steps within a graph algorithm. Unlike the STL algorithms, graph
|
|
algorithms typically have multiple event points where one may want to
|
|
insert a call-back via a functor. Therefore visitors do not have a
|
|
single <tt>operator()</tt> method like a functor, but instead have
|
|
several methods that correspond to the various event points. Each
|
|
algorithm has a different set of event points, which are described by
|
|
the following visitor concepts:
|
|
|
|
<ul>
|
|
<li> <a href="./BFSVisitor.html">BFS Visitor</a>
|
|
<li> <a href="./DFSVisitor.html">DFS Visitor</a>
|
|
<li> <a href="./UniformCostVisitor.html">Uniform Cost Visitor</a>
|
|
<li> <a href="./BellmanFordVisitor.html">Bellman Ford Visitor</a>
|
|
<li> <a href="./EventVisitor.html">Event Visitor</a>
|
|
</ul>
|
|
|
|
|
|
<br>
|
|
<HR>
|
|
<TABLE>
|
|
<TR valign=top>
|
|
<TD nowrap>Copyright © 2000</TD><TD>
|
|
<A HREF="../../../people/jeremy_siek.htm">Jeremy Siek</A>,
|
|
Univ.of Notre Dame (<A
|
|
HREF="mailto:jsiek@lsc.nd.edu">jsiek@lsc.nd.edu</A>)<br>
|
|
<A HREF="../../../people/liequan_lee.htm">Lie-Quan Lee</A>, Univ.of Notre Dame (<A HREF="mailto:llee1@lsc.nd.edu">llee1@lsc.nd.edu</A>)<br>
|
|
<A HREF=http://www.lsc.nd.edu/~lums>Andrew Lumsdaine</A>,
|
|
Univ.of Notre Dame (<A
|
|
HREF="mailto:lums@lsc.nd.edu">lums@lsc.nd.edu</A>)
|
|
</TD></TR></TABLE>
|
|
|
|
</BODY>
|
|
</HTML>
|