- java.lang.Object
-
- org.jgrapht.alg.flow.MaximumFlowAlgorithmBase.VertexExtensionBase
-
- org.jgrapht.alg.flow.BoykovKolmogorovMFImpl.VertexExtension
-
- All Implemented Interfaces:
Extension
- Enclosing class:
- BoykovKolmogorovMFImpl<V,E>
private class BoykovKolmogorovMFImpl.VertexExtension extends MaximumFlowAlgorithmBase.VertexExtensionBase
Network vertex extension used to store auxiliary vertex information.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) booleanactiveIf this vertex is in the active vertex list.(package private) intdistanceThe distance of this vertex to a terminal vertex (network source or sink).(package private) MaximumFlowAlgorithmBase.AnnotatedFlowEdgeparentEdgeEdge to the tree parent.(package private) longtimestampThis vertex timestamp.(package private) BoykovKolmogorovMFImpl.VertexTreeStatustreeStatusTree status of this vertex.-
Fields inherited from class org.jgrapht.alg.flow.MaximumFlowAlgorithmBase.VertexExtensionBase
excess, prototype
-
-
Constructor Summary
Constructors Constructor Description VertexExtension()Creates a new free vertex.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) BoykovKolmogorovMFImpl.VertexExtensiongetParent()Returns the parent of this vertex.(package private) booleanisFreeVertex()Checks if this vertex belongs to no tree, i.e.(package private) booleanisSinkTreeVertex()Checks if this vertex belongs to the sink tree.(package private) booleanisSourceTreeVertex()Checks if this vertex belongs to the source tree.(package private) voidmakeOrphan()Disconnects this vertex from its parent.java.lang.StringtoString()-
Methods inherited from class org.jgrapht.alg.flow.MaximumFlowAlgorithmBase.VertexExtensionBase
getOutgoing
-
-
-
-
Field Detail
-
timestamp
long timestamp
This vertex timestamp. The timestamp is the last iteration in which the distance to terminal of this vertex was updated. If this value isn't equal to the most recent iteration index, the distance value may be outdated.
-
distance
int distance
The distance of this vertex to a terminal vertex (network source or sink). This value may not represent the actual distance as it's not updated every iteration.
-
active
boolean active
If this vertex is in the active vertex list.
-
parentEdge
MaximumFlowAlgorithmBase.AnnotatedFlowEdge parentEdge
Edge to the tree parent.
-
treeStatus
BoykovKolmogorovMFImpl.VertexTreeStatus treeStatus
Tree status of this vertex.
-
-
Method Detail
-
isSourceTreeVertex
boolean isSourceTreeVertex()
Checks if this vertex belongs to the source tree.- Returns:
trueif this vertex belongs to the source tree,falseotherwise.
-
isSinkTreeVertex
boolean isSinkTreeVertex()
Checks if this vertex belongs to the sink tree.- Returns:
trueif this vertex belongs to the sink tree,falseotherwise.
-
isFreeVertex
boolean isFreeVertex()
Checks if this vertex belongs to no tree, i.e. is a free vertex.- Returns:
trueif this vertex is free,falseotherwise.
-
makeOrphan
void makeOrphan()
Disconnects this vertex from its parent.
-
getParent
BoykovKolmogorovMFImpl.VertexExtension getParent()
Returns the parent of this vertex.- Returns:
- the parent of this vertex.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-