V
- the graph vertex typeE
- the graph edge typepublic class SimpleWeightedBipartiteGraphMatrixGenerator<V,E> extends WeightedGraphGeneratorAdapter<V,E,V> implements GraphGenerator<V,E,V>
Modifier and Type | Field and Description |
---|---|
protected List<V> |
first |
protected List<V> |
second |
protected double[][] |
weights |
Constructor and Description |
---|
SimpleWeightedBipartiteGraphMatrixGenerator() |
Modifier and Type | Method and Description |
---|---|
SimpleWeightedBipartiteGraphMatrixGenerator<V,E> |
first(List<? extends V> first)
Set the first partition of the generator.
|
void |
generateGraph(Graph<V,E> target,
VertexFactory<V> vertexFactory,
Map<String,V> resultMap)
Generate a graph structure.
|
void |
generateGraph(WeightedGraph<V,E> target,
VertexFactory<V> vertexFactory,
Map<String,V> resultMap)
Deprecated.
Not needed since
WeightedGraph is deprecated. |
SimpleWeightedBipartiteGraphMatrixGenerator<V,E> |
second(List<? extends V> second)
Set the second partition of the generator.
|
SimpleWeightedBipartiteGraphMatrixGenerator<V,E> |
weights(double[][] weights)
Set the weights of the generator.
|
public SimpleWeightedBipartiteGraphMatrixGenerator()
public SimpleWeightedBipartiteGraphMatrixGenerator<V,E> first(List<? extends V> first)
first
- the first partitionpublic SimpleWeightedBipartiteGraphMatrixGenerator<V,E> second(List<? extends V> second)
second
- the second partitionpublic SimpleWeightedBipartiteGraphMatrixGenerator<V,E> weights(double[][] weights)
weights
in class WeightedGraphGeneratorAdapter<V,E,V>
weights
- the weightspublic void generateGraph(Graph<V,E> target, VertexFactory<V> vertexFactory, Map<String,V> resultMap)
generateGraph
in interface GraphGenerator<V,E,V>
generateGraph
in class WeightedGraphGeneratorAdapter<V,E,V>
target
- receives the generated edges and vertices; if this is non-empty on entry, the
result will be a disconnected graph since generated elements will not be connected to
existing elementsvertexFactory
- called to produce new verticesresultMap
- if non-null, receives implementation-specific mappings from String roles to
graph elements (or collections of graph elements)@Deprecated public void generateGraph(WeightedGraph<V,E> target, VertexFactory<V> vertexFactory, Map<String,V> resultMap)
WeightedGraph
is deprecated.generateGraph
in class WeightedGraphGeneratorAdapter<V,E,V>
target
- receives the generated edges and vertices; if this is non-empty on entry, the
result will be a disconnected graph since generated elements will not be connected to
existing elementsvertexFactory
- called to produce new verticesresultMap
- if non-null, receives implementation-specific mappings from String roles to
graph elements (or collections of graph elements)Copyright © 2017. All rights reserved.