edu.iu.iv.modeling.p2p.hypergrid
Class HypergridAlgorithm

java.lang.Object
  |
  +--edu.iu.iv.modeling.p2p.hypergrid.HypergridAlgorithm
All Implemented Interfaces:
Algorithm

public class HypergridAlgorithm
extends java.lang.Object
implements Algorithm

Wrapper for Hypergrid Network Modeling Algorithm

Author:
Hardik Sheth (hsheth@indiana.edu)

Constructor Summary
HypergridAlgorithm(int networkSize, int degree)
          Constructor for HypergridAlgorithm class.
 
Method Summary
 boolean execute()
          Runs the algorithm.
 int getDegree()
          Get the degree of nodes in the Hypergrid network
 java.lang.String getFileName()
          This method gets the name of the file that stores the network graph
 int getNetworkSize()
          This method gets the size of the network
 void setDegree(int degree)
          Set the degree of nodes in the Hypergrid network
 void setFileName(java.lang.String filename)
          This method sets the name of the file which'll store the network graph
 void setNetworkSize(int networkSize)
          This method sets the size of the network to be built
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HypergridAlgorithm

public HypergridAlgorithm(int networkSize,
                          int degree)
Constructor for HypergridAlgorithm class. It sets the network size and the minimum degree of the node

Parameters:
networkSize - - size of the network
degree - - degree of the node
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()

setNetworkSize

public void setNetworkSize(int networkSize)
This method sets the size of the network to be built

Parameters:
networkSize -

getNetworkSize

public int getNetworkSize()
This method gets the size of the network

Returns:
network size

getFileName

public java.lang.String getFileName()
This method gets the name of the file that stores the network graph

Returns:
String

setFileName

public void setFileName(java.lang.String filename)
This method sets the name of the file which'll store the network graph

Parameters:
filename -

getDegree

public int getDegree()
Get the degree of nodes in the Hypergrid network

Returns:
degree

setDegree

public void setDegree(int degree)
Set the degree of nodes in the Hypergrid network

Parameters:
degree - degree of nodes