massim.competition2011.scenario
Class GraphGenerator

java.lang.Object
  extended by massim.competition2011.scenario.GraphGenerator
Direct Known Subclasses:
GraphGeneratorTriangulation, GraphGeneratorTriangulationBalanced

public abstract class GraphGenerator
extends java.lang.Object

This abstract class should be overridden by the classes that will be used to generate different variations of graphs (maps).


Constructor Summary
GraphGenerator()
           
 
Method Summary
abstract  void generate(java.util.Vector<GraphNode> nodes, java.util.Vector<GraphEdge> edges, int nodesNum, int gridWidth, int gridHeight, int cellWidth, int minNodeWeight, int maxNodeWeight, int minEdgeCost, int maxEdgeCost, int nodeWeighting, java.util.Random random)
          Generates a graph.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GraphGenerator

public GraphGenerator()
Method Detail

generate

public abstract void generate(java.util.Vector<GraphNode> nodes,
                              java.util.Vector<GraphEdge> edges,
                              int nodesNum,
                              int gridWidth,
                              int gridHeight,
                              int cellWidth,
                              int minNodeWeight,
                              int maxNodeWeight,
                              int minEdgeCost,
                              int maxEdgeCost,
                              int nodeWeighting,
                              java.util.Random random)
Generates a graph.

Parameters:
nodes - an empty Vector<GraphNode> where the nodes of the new graph shall be added.
edges - an empty Vector<GraphEdge> where the edges of the new graph shall be added.
nodesNum - Number of node that the generated graph will have.
gridWidth -
gridHeight -
cellWidth -
minNodeWeight -
maxNodeWeight -
minEdgeCost -
maxEdgeCost -
nodeWeighting -


Copyright © 2011. All Rights Reserved.