Module org.jhotdraw8.graph
Class AbstractBackLinkWithCost<T extends AbstractBackLinkWithCost<T,C>,C extends Number & Comparable<C>>
java.lang.Object
org.jhotdraw8.graph.path.backlink.AbstractBackLink<T>
org.jhotdraw8.graph.path.backlink.AbstractBackLinkWithCost<T,C>
- Type Parameters:
T- the concrete back link typeC- the cost number type
- Direct Known Subclasses:
ArcBackLinkWithCost,IndexedVertexBackLinkWithCost,VertexBackLinkWithCost
public class AbstractBackLinkWithCost<T extends AbstractBackLinkWithCost<T,C>,C extends Number & Comparable<C>>
extends AbstractBackLink<T>
Abstract base class for back links.
-
Field Summary
Fields inherited from class org.jhotdraw8.graph.path.backlink.AbstractBackLink
depth, parent -
Constructor Summary
ConstructorsConstructorDescriptionAbstractBackLinkWithCost(@Nullable T parent, @NonNull C cost) Creates a new instance. -
Method Summary
Methods inherited from class org.jhotdraw8.graph.path.backlink.AbstractBackLink
getDepth, getParent
-
Constructor Details
-
AbstractBackLinkWithCost
Creates a new instance.- Parameters:
parent- the parent back linkcost- the cumulated cost of this back link. Must be zero if parent is null.
-
-
Method Details
-
getCost
The cost- Returns:
- cost
-