edu.mit.ll.group43.surfaceoptimization.dp.factory.cost
Class CostStrategy

java.lang.Object
  extended by edu.mit.ll.group43.surfaceoptimization.dp.factory.cost.CostStrategy
Direct Known Subclasses:
RunwayCostStrategy, SpotCostStrategy

public abstract class CostStrategy
extends java.lang.Object

This abstract class is extended by classes that act as edge cost strategies for the DPSequencer. These classes are responsible for helping to solve the shortest path in the generated CPS network by correctly initializing nodes in the first stage, calculating what a given edge weight should be, and properly updating the values of a given node to ensure an optimal solution is achieved.

Author:
William Hawkins

Constructor Summary
CostStrategy(int cps, MinimumSeparationCalculator<? extends WeightClass> calc)
           
 
Method Summary
abstract  int getEdgeWeight(NetworkEdge edge)
          Returns the additional delay incurred when the optimal spot release time of the last aircraft of the target node of the edge is calculated immediately after that of the source node of the edge.
abstract  void initializeFirstStage(java.util.ArrayList<java.util.TreeSet<CPSNetworkNode>> network)
          Initializes the first stage of the CPS network so that subsequent stages may be solved for.
abstract  void setOptimalValues(NetworkEdge edge, int distance)
          Sets the optimal values of the node currently being solved, as well as for its last aircraft.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CostStrategy

public CostStrategy(int cps,
                    MinimumSeparationCalculator<? extends WeightClass> calc)
Method Detail

initializeFirstStage

public abstract void initializeFirstStage(java.util.ArrayList<java.util.TreeSet<CPSNetworkNode>> network)
Initializes the first stage of the CPS network so that subsequent stages may be solved for.

Parameters:
network -

setOptimalValues

public abstract void setOptimalValues(NetworkEdge edge,
                                      int distance)
Sets the optimal values of the node currently being solved, as well as for its last aircraft.

Parameters:
edge -
distance -

getEdgeWeight

public abstract int getEdgeWeight(NetworkEdge edge)
Returns the additional delay incurred when the optimal spot release time of the last aircraft of the target node of the edge is calculated immediately after that of the source node of the edge.

Parameters:
edge -
Returns: