|
@@ -2,34 +2,25 @@ package classes;
|
|
|
|
|
|
public class Edge {
|
|
|
|
|
|
- final float maxCapacity;
|
|
|
- float curCapacity;
|
|
|
-
|
|
|
+ final float capacity;
|
|
|
+ float flow;
|
|
|
+
|
|
|
CpsObject A;
|
|
|
CpsObject B;
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- Edge(CpsObject A, CpsObject B, float maxCapacity){
|
|
|
+ Edge(CpsObject A, CpsObject B, float capacity) {
|
|
|
setA(A);
|
|
|
setB(B);
|
|
|
- this.maxCapacity = maxCapacity;
|
|
|
+ this.capacity = capacity;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
/**
|
|
|
* @return the capacity
|
|
|
*/
|
|
|
public float getCapacity() {
|
|
|
- return maxCapacity;
|
|
|
+ return capacity;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
* @return the a
|
|
|
*/
|
|
@@ -37,15 +28,14 @@ public class Edge {
|
|
|
return A;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
- * @param a the a to set
|
|
|
+ * @param a
|
|
|
+ * the a to set
|
|
|
*/
|
|
|
public void setA(CpsObject a) {
|
|
|
A = a;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
* @return the b
|
|
|
*/
|
|
@@ -53,9 +43,9 @@ public class Edge {
|
|
|
return B;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
- * @param b the b to set
|
|
|
+ * @param b
|
|
|
+ * the b to set
|
|
|
*/
|
|
|
public void setB(CpsObject b) {
|
|
|
B = b;
|