java.lang.Object
org.jgrapht.alg.StoerWagnerMinimumCut.VertexAndWeight
- All Implemented Interfaces:
java.lang.Comparable<StoerWagnerMinimumCut.VertexAndWeight>
- Enclosing class:
- StoerWagnerMinimumCut<V,E>
protected class StoerWagnerMinimumCut.VertexAndWeight extends java.lang.Object implements java.lang.Comparable<StoerWagnerMinimumCut.VertexAndWeight>
Class for weighted vertices
-
Field Summary
-
Constructor Summary
Constructors Constructor Description VertexAndWeight(java.util.Set<V> v, double w, boolean active)Construct a new weighted vertex. -
Method Summary
Modifier and Type Method Description intcompareTo(StoerWagnerMinimumCut.VertexAndWeight that)compareTo that sorts in reverse order because we need extract-max and queue provides extract-min.java.lang.StringtoString()
-
Field Details
-
Constructor Details
-
VertexAndWeight
Construct a new weighted vertex.- Parameters:
v- the vertexw- the weight of the vertexactive- whether it is active
-
-
Method Details
-
compareTo
compareTo that sorts in reverse order because we need extract-max and queue provides extract-min.- Specified by:
compareToin interfacejava.lang.Comparable<StoerWagnerMinimumCut.VertexAndWeight>
-
toString
public java.lang.String toString()- Overrides:
toStringin classjava.lang.Object
-