Module org.jgrapht.core
Package org.jgrapht.alg.interfaces
Class MinimumCostFlowAlgorithm.MinimumCostFlowImpl<E>
java.lang.Object
org.jgrapht.alg.interfaces.FlowAlgorithm.FlowImpl<E>
org.jgrapht.alg.interfaces.MinimumCostFlowAlgorithm.MinimumCostFlowImpl<E>
- Type Parameters:
E- graph edge type
- All Implemented Interfaces:
FlowAlgorithm.Flow<E>,MinimumCostFlowAlgorithm.MinimumCostFlow<E>
- Enclosing interface:
- MinimumCostFlowAlgorithm<V,E>
public static class MinimumCostFlowAlgorithm.MinimumCostFlowImpl<E> extends FlowAlgorithm.FlowImpl<E> implements MinimumCostFlowAlgorithm.MinimumCostFlow<E>
Default implementation of the
MinimumCostFlowAlgorithm.MinimumCostFlow-
Constructor Summary
Constructors Constructor Description MinimumCostFlowImpl(double cost, java.util.Map<E,java.lang.Double> flowMap)Constructs a new instance of minimum cost flow -
Method Summary
Modifier and Type Method Description doublegetCost()Returns the cost of the flow
-
Constructor Details
-
MinimumCostFlowImpl
Constructs a new instance of minimum cost flow- Parameters:
cost- the cost of the flowflowMap- the mapping defining the flow on the network
-
-
Method Details
-
getCost
public double getCost()Returns the cost of the flow- Specified by:
getCostin interfaceMinimumCostFlowAlgorithm.MinimumCostFlow<E>- Returns:
- the cost of the flow
-