edu.iu.iv.modeling.p2p.errorTolerance
Class ErrorTolerance

java.lang.Object
  |
  +--edu.iu.iv.modeling.p2p.errorTolerance.ErrorTolerance

public class ErrorTolerance
extends java.lang.Object

Perform Error Tolerance Test on the network graph. Randomly deletes nodes in the graph.

Author:
Hardik Sheth (hsheth@indiana.edu)

Constructor Summary
ErrorTolerance(edu.uci.ics.jung.graph.Graph graph, int numNodes)
          Constructor for ErrorTolerance.
 
Method Summary
 edu.uci.ics.jung.graph.Graph getGraph()
          Get the graph representing the network
 int getNumNodes()
          Get the number of nodes that are randomly deleted
 void setGraph(edu.uci.ics.jung.graph.Graph graph)
          Set the graph representing the network
 void setNumNodes(int i)
          Set the number of nodes that are randomly deleted
 boolean testErrorTolerance()
          Perform error tolerance test on the graph.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ErrorTolerance

public ErrorTolerance(edu.uci.ics.jung.graph.Graph graph,
                      int numNodes)
Constructor for ErrorTolerance. Requires a graph to be passed that represents the network and the number of nodes to be deleted randomly.

Method Detail

testErrorTolerance

public boolean testErrorTolerance()
Perform error tolerance test on the graph.

Returns:
true when test done.

getGraph

public edu.uci.ics.jung.graph.Graph getGraph()
Get the graph representing the network

Returns:
graph

getNumNodes

public int getNumNodes()
Get the number of nodes that are randomly deleted

Returns:

setGraph

public void setGraph(edu.uci.ics.jung.graph.Graph graph)
Set the graph representing the network

Parameters:
graph -

setNumNodes

public void setNumNodes(int i)
Set the number of nodes that are randomly deleted

Parameters:
i -