edu.iu.iv.search.p2p.bfs
Class BreadthFirstSearchAlgorithm

java.lang.Object
  |
  +--edu.iu.iv.search.p2p.bfs.BreadthFirstSearchAlgorithm
All Implemented Interfaces:
Algorithm

public class BreadthFirstSearchAlgorithm
extends java.lang.Object
implements Algorithm

Wrapper for BFS Algorithm

Author:
Hardik Sheth (hsheth@indiana.edu)

Constructor Summary
BreadthFirstSearchAlgorithm()
          Empty Constructor
BreadthFirstSearchAlgorithm(edu.uci.ics.jung.graph.Graph graph, int sourceNode, int targetNode, double threshold)
          Constructor for BreadthFirstSearchAlgorithm.
 
Method Summary
 boolean execute()
          Runs the algorithm.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BreadthFirstSearchAlgorithm

public BreadthFirstSearchAlgorithm(edu.uci.ics.jung.graph.Graph graph,
                                   int sourceNode,
                                   int targetNode,
                                   double threshold)
Constructor for BreadthFirstSearchAlgorithm. Sets the source and target nodes for search, the file containing the graph and the threshold to perform search.

Parameters:
sourceNode -
targetNode -
threshold -

BreadthFirstSearchAlgorithm

public BreadthFirstSearchAlgorithm()
Empty Constructor

Method Detail

execute

public boolean execute()
Description copied from interface: Algorithm
Runs the algorithm.

Specified by:
execute in interface Algorithm
Returns:
true if the algorithm ran successfully, false otherwise.
See Also:
Algorithm.execute()