Class ImprovementSearchLimit


  • public class ImprovementSearchLimit
    extends SearchLimit
    • Constructor Detail

      • ImprovementSearchLimit

        protected ImprovementSearchLimit​(long cPtr,
                                         boolean cMemoryOwn)
      • ImprovementSearchLimit

        public ImprovementSearchLimit​(Solver solver,
                                      IntVar objective_var,
                                      boolean maximize,
                                      double objective_scaling_factor,
                                      double objective_offset,
                                      double improvement_rate_coefficient,
                                      int improvement_rate_solutions_distance)
      • ImprovementSearchLimit

        public ImprovementSearchLimit​(Solver solver,
                                      IntVar[] objective_vars,
                                      SWIGTYPE_p_std__vectorT_bool_t maximize,
                                      double[] objective_scaling_factors,
                                      double[] objective_offsets,
                                      double improvement_rate_coefficient,
                                      int improvement_rate_solutions_distance)
    • Method Detail

      • copy

        public void copy​(SearchLimit limit)
        Description copied from class: SearchLimit
        Copy a limit. Warning: leads to a direct (no check) downcasting of 'limit'
        so one needs to be sure both SearchLimits are of the same type.
        Overrides:
        copy in class SearchLimit
      • atSolution

        public boolean atSolution()
        Description copied from class: SearchMonitor
        This method is called when a valid solution is found. If the
        return value is true, then search will resume after. If the result
        is false, then search will stop there.
        Overrides:
        atSolution in class SearchMonitor
      • init

        public void init()
        Description copied from class: SearchLimit
        This method is called when the search limit is initialized.
        Overrides:
        init in class SearchLimit
      • install

        public void install()
        Description copied from class: SearchMonitor
        Registers itself on the solver such that it gets notified of the search
        and propagation events. Override to incrementally install listeners for
        specific events.
        Overrides:
        install in class SearchLimit