Class SwitchNotFeasible

java.lang.Object
com.graphhopper.jsprit.core.problem.constraint.SwitchNotFeasible
All Implemented Interfaces:
Constraint, HardConstraint, HardRouteConstraint

public class SwitchNotFeasible extends Object implements HardRouteConstraint
Created by schroeder on 19/09/15.
  • Constructor Details

    • SwitchNotFeasible

      public SwitchNotFeasible(StateManager stateManager)
  • Method Details

    • fulfilled

      public boolean fulfilled(JobInsertionContext insertionContext)
      Description copied from interface: HardRouteConstraint
      Returns whether a job can be inserted in route.
      Specified by:
      fulfilled in interface HardRouteConstraint
      Parameters:
      insertionContext - provides context information about inserting a new job, i.e. the new job (insertionContext.getJob()), the route where the new job should be inserted (insertionContext.getRoute()), the new vehicle that should operate the route plus the new job (insertionContext.getNewVehicle()) and the new departure time at this vehicle's start location (insertionContext.getNewDepartureTime()).
      Returns:
      true if constraint is met, false otherwise