protected class StoerWagnerMinimumCut.VertexAndWeight extends java.lang.Object implements java.lang.Comparable<StoerWagnerMinimumCut.VertexAndWeight>
| Modifier and Type | Field and Description |
|---|---|
boolean |
active |
java.util.Set<V> |
vertex |
java.lang.Double |
weight |
| Constructor and Description |
|---|
VertexAndWeight(java.util.Set<V> v,
double w,
boolean active)
Construct a new weighted vertex.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(StoerWagnerMinimumCut.VertexAndWeight that)
compareTo that sorts in reverse order because we need extract-max and queue provides
extract-min.
|
java.lang.String |
toString() |
public java.util.Set<V> vertex
public java.lang.Double weight
public boolean active
public VertexAndWeight(java.util.Set<V> v, double w, boolean active)
v - the vertexw - the weight of the vertexactive - whether it is activepublic int compareTo(StoerWagnerMinimumCut.VertexAndWeight that)
compareTo in interface java.lang.Comparable<StoerWagnerMinimumCut.VertexAndWeight>public java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2019. All Rights Reserved.