graphlab.plugins.graphgenerator.generators
Class TreeGenerator
java.lang.Object
graphlab.plugins.graphgenerator.generators.TreeGenerator
- All Implemented Interfaces:
- BasicExtension, Extension, Parametrizable, GraphGeneratorExtension, GraphGeneratorInterface, SimpleGeneratorInterface
public class TreeGenerator
- extends java.lang.Object
- implements GraphGeneratorExtension, Parametrizable, SimpleGeneratorInterface
- Author:
- azin azadi, Hoshmand Hasannia
Field Summary |
static java.lang.Integer |
degree
|
static java.lang.Integer |
depth
|
static ArrayX<java.lang.String> |
m
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
depth
public static java.lang.Integer depth
degree
public static java.lang.Integer degree
m
public static ArrayX<java.lang.String> m
TreeGenerator
public TreeGenerator()
setWorkingGraph
public void setWorkingGraph(GraphModel g)
- Specified by:
setWorkingGraph
in interface SimpleGeneratorInterface
getName
public java.lang.String getName()
- Specified by:
getName
in interface Extension
getDescription
public java.lang.String getDescription()
- Specified by:
getDescription
in interface Extension
getVertices
public VertexModel[] getVertices()
- Specified by:
getVertices
in interface SimpleGeneratorInterface
getEdges
public EdgeModel[] getEdges()
- Specified by:
getEdges
in interface SimpleGeneratorInterface
getVertexPositionsBackward
public java.awt.Point[] getVertexPositionsBackward()
getVertexPositions
public java.awt.Point[] getVertexPositions()
- Specified by:
getVertexPositions
in interface SimpleGeneratorInterface
getVertexPositionsCircular
public java.awt.Point[] getVertexPositionsCircular()
checkParameters
public java.lang.String checkParameters()
- Description copied from interface:
Parametrizable
- checks the parameters and return an error string if the parameter
values are invalid, otherwise it returns null,
also if some other fields should be set after setting the parameters
you can do it in this method
- Specified by:
checkParameters
in interface Parametrizable
generateGraph
public GraphModel generateGraph()
- Specified by:
generateGraph
in interface GraphGeneratorInterface
generateTree
public static GraphModel generateTree(int depth,
int degree)
- generates a Complete Tree with given parameters