public abstract class SNTGraph<V,E extends org.jgrapht.graph.DefaultWeightedEdge>
extends org.jgrapht.graph.AbstractBaseGraph<V,E>
Modifier | Constructor and Description |
---|---|
protected |
SNTGraph(Supplier<V> vertexSupplier,
Supplier<E> edgeSupplier,
org.jgrapht.GraphType type) |
Modifier and Type | Method and Description |
---|---|
void |
applyEdges(UnaryOperator<E> operator)
Apply the given operator over the edge set.
|
void |
applyVertices(UnaryOperator<V> operator)
Apply the given operator over the vertex set.
|
void |
filterEdges(Predicate<E> predicate)
Remove edges from this graph that do not match the given predicate.
|
void |
filterVertices(Predicate<V> predicate)
Remove vertices from this graph that do not match the given predicate.
|
ColorRGB |
getEdgeColor(E edge) |
Map<E,ColorRGB> |
getEdgeColorRGBMap() |
ColorRGB |
getVertexColor(V vertex) |
Map<V,ColorRGB> |
getVertexColorRGBMap() |
double |
getVertexValue(V vertex) |
Map<V,Double> |
getVertexValueMap() |
void |
setEdgeColor(E edge,
ColorRGB color) |
void |
setVertexColor(V vertex,
ColorRGB color) |
void |
setVertexValue(V vertex,
double value) |
addEdge, addEdge, addVertex, addVertex, clone, containsEdge, containsVertex, degreeOf, edgeSet, edgesOf, getAllEdges, getEdge, getEdgeSource, getEdgeSupplier, getEdgeTarget, getEdgeWeight, getType, getVertexSupplier, incomingEdgesOf, inDegreeOf, outDegreeOf, outgoingEdgesOf, removeEdge, removeEdge, removeVertex, setEdgeSupplier, setEdgeWeight, setVertexSupplier, vertexSet
assertVertexExist, containsEdge, equals, hashCode, removeAllEdges, removeAllEdges, removeAllEdges, removeAllVertices, toString, toStringFromSets
public void setVertexValue(V vertex, double value)
public double getVertexValue(V vertex)
public void filterVertices(Predicate<V> predicate)
predicate
- a non-interfering, stateless predicate to apply to each vertex to determine if it
should be retained in the vertex set.public void filterEdges(Predicate<E> predicate)
predicate
- a non-interfering, stateless predicate to apply to each edge to determine if it
should be retained in the edge set.public void applyVertices(UnaryOperator<V> operator)
operator
- a non-interfering, stateless operator to apply to each vertexpublic void applyEdges(UnaryOperator<E> operator)
operator
- a non-interfering, stateless operator to apply to each edgeCopyright © 2015–2021 Fiji. All rights reserved.