infovis.graph.algorithm
Class BreadthFirst

java.lang.Object
  extended by infovis.graph.algorithm.Algorithm
      extended by infovis.graph.algorithm.BreadthFirst

public class BreadthFirst
extends Algorithm

Breadth first search algorithm for Graphs.

Version:
$Revision: 1.3 $
Author:
Jean-Daniel Fekete

Nested Class Summary
static interface BreadthFirst.Visitor
           
 
Field Summary
 
Fields inherited from class infovis.graph.algorithm.Algorithm
BLACK, GREY, WHITE
 
Constructor Summary
BreadthFirst(Graph graph)
          Constructor for BreadthFirst.
 
Method Summary
 void visit(BreadthFirst.Visitor vis, int start)
          Performs a breadth-first traversal of a graph.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BreadthFirst

public BreadthFirst(Graph graph)
Constructor for BreadthFirst.

Method Detail

visit

public void visit(BreadthFirst.Visitor vis,
                  int start)
Performs a breadth-first traversal of a graph.

Parameters:
vis - the Visitor
start - the starting vertex


Copyright 2005 by Jean-Daniel Fekete and INRIA, France All rights reserved.