Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
Public Member Functions | |
synchronized void | delete () |
void | swigReleaseOwnership () |
void | swigTakeOwnership () |
PathOperator (IntVar[] next_vars, IntVar[] path_vars, SWIGTYPE_p_operations_research__PathOperator__IterationParameters iteration_parameters) | |
PathOperator (IntVar[] next_vars, IntVar[] path_vars, int number_of_base_nodes, boolean skip_locally_optimal_paths, boolean accept_path_end_base, LongToIntFunction start_empty_path_class, SWIGTYPE_p_std__functionT_std__vectorT_int_t_const_Rfint_intF_t get_neighbors) | |
boolean | neighbor () |
void | reset () |
long | Prev (long node) |
Public Member Functions inherited from com.google.ortools.constraintsolver.IntVarLocalSearchOperator | |
IntVarLocalSearchOperator (IntVar[] vars, boolean keep_inverse_values) | |
IntVarLocalSearchOperator (IntVar[] vars) | |
boolean | HoldsDelta () |
void | start (Assignment assignment) |
boolean | isIncremental () |
int | size () |
long | value (long index) |
IntVar | var (long index) |
boolean | SkipUnchanged (int index) |
long | oldValue (long index) |
long | PrevValue (long index) |
void | setValue (long index, long value) |
boolean | activated (long index) |
void | activate (long index) |
void | deactivate (long index) |
boolean | ApplyChanges (Assignment delta, Assignment deltadelta) |
void | RevertChanges (boolean change_was_incremental) |
void | addVars (IntVar[] vars) |
void | onStart () |
Public Member Functions inherited from com.google.ortools.constraintsolver.LocalSearchOperator | |
LocalSearchOperator () | |
boolean | nextNeighbor (Assignment delta, Assignment deltadelta) |
boolean | HasFragments () |
Public Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
BaseObject () | |
String | toString () |
Protected Member Functions | |
PathOperator (long cPtr, boolean cMemoryOwn) | |
void | finalize () |
void | swigDirectorDisconnect () |
boolean | oneNeighbor () |
void | OnNodeInitialization () |
boolean | restartAtPathStartOnSynchronize () |
boolean | onSamePathAsPreviousBase (long base_index) |
long | getBaseNodeRestartPosition (int base_index) |
void | setNextBaseToIncrement (long base_index) |
boolean | ConsiderAlternatives (long base_index) |
boolean | initPosition () |
Protected Member Functions inherited from com.google.ortools.constraintsolver.IntVarLocalSearchOperator | |
IntVarLocalSearchOperator (long cPtr, boolean cMemoryOwn) | |
Protected Member Functions inherited from com.google.ortools.constraintsolver.LocalSearchOperator | |
LocalSearchOperator (long cPtr, boolean cMemoryOwn) | |
Protected Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
BaseObject (long cPtr, boolean cMemoryOwn) | |
Static Protected Member Functions | |
static long | getCPtr (PathOperator obj) |
static long | swigRelease (PathOperator obj) |
Static Protected Member Functions inherited from com.google.ortools.constraintsolver.IntVarLocalSearchOperator | |
static long | getCPtr (IntVarLocalSearchOperator obj) |
static long | swigRelease (IntVarLocalSearchOperator obj) |
Static Protected Member Functions inherited from com.google.ortools.constraintsolver.LocalSearchOperator | |
static long | getCPtr (LocalSearchOperator obj) |
static long | swigRelease (LocalSearchOperator obj) |
Static Protected Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
static long | getCPtr (BaseObject obj) |
static long | swigRelease (BaseObject obj) |
Additional Inherited Members | |
Protected Attributes inherited from com.google.ortools.constraintsolver.BaseObject | |
transient boolean | swigCMemOwn |
Base class of the local search operators dedicated to path modifications
(a path is a set of nodes linked together by arcs).
This family of neighborhoods supposes they are handling next variables
representing the arcs (var[i] represents the node immediately after i on
a path).
Several services are provided:
Definition at line 30 of file PathOperator.java.
|
protected |
Definition at line 33 of file PathOperator.java.
com.google.ortools.constraintsolver.PathOperator.PathOperator | ( | IntVar[] | next_vars, |
IntVar[] | path_vars, | ||
SWIGTYPE_p_operations_research__PathOperator__IterationParameters | iteration_parameters ) |
Builds an instance of PathOperator from next and path variables.
Definition at line 88 of file PathOperator.java.
com.google.ortools.constraintsolver.PathOperator.PathOperator | ( | IntVar[] | next_vars, |
IntVar[] | path_vars, | ||
int | number_of_base_nodes, | ||
boolean | skip_locally_optimal_paths, | ||
boolean | accept_path_end_base, | ||
LongToIntFunction | start_empty_path_class, | ||
SWIGTYPE_p_std__functionT_std__vectorT_int_t_const_Rfint_intF_t | get_neighbors ) |
Definition at line 93 of file PathOperator.java.
|
protected |
Indicates if alternatives should be considered when iterating over base
nodes.
Definition at line 174 of file PathOperator.java.
synchronized void com.google.ortools.constraintsolver.PathOperator.delete | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 59 of file PathOperator.java.
|
protected |
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 55 of file PathOperator.java.
|
protected |
Returns the index of the node to which the base node of index base_index
must be set to when it reaches the end of a path.
By default, it is set to the start of the current path.
When this method is called, one can only assume that base nodes with
indices < base_index have their final position.
Definition at line 158 of file PathOperator.java.
|
staticprotected |
Definition at line 38 of file PathOperator.java.
|
protected |
Returns true if the operator needs to restart its initial position at each
call to Start()
Definition at line 182 of file PathOperator.java.
boolean com.google.ortools.constraintsolver.PathOperator.neighbor | ( | ) |
Definition at line 98 of file PathOperator.java.
|
protected |
This method should not be overridden. Override MakeNeighbor() instead.
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 116 of file PathOperator.java.
|
protected |
Called by OnStart() after initializing node information. Should be
overridden instead of OnStart() to avoid calling PathOperator::OnStart
explicitly.
Definition at line 125 of file PathOperator.java.
|
protected |
Returns true if a base node has to be on the same path as the "previous"
base node (base node of index base_index - 1).
Useful to limit neighborhood exploration to nodes on the same path.
it's currently way more complicated to implement.
Definition at line 147 of file PathOperator.java.
long com.google.ortools.constraintsolver.PathOperator.Prev | ( | long | node | ) |
Returns the node before node in the current delta.
Definition at line 109 of file PathOperator.java.
void com.google.ortools.constraintsolver.PathOperator.reset | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.LocalSearchOperator.
Definition at line 102 of file PathOperator.java.
|
protected |
When the operator is being synchronized with a new solution (when Start()
is called), returns true to restart the exploration of the neighborhood
from the start of the last paths explored; returns false to restart the
exploration at the last nodes visited.
This is used to avoid restarting on base nodes which have changed paths,
leading to potentially skipping neighbors.
Definition at line 137 of file PathOperator.java.
|
protected |
Set the next base to increment on next iteration. All base > base_index
will be reset to their start value.
Definition at line 166 of file PathOperator.java.
|
protected |
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 70 of file PathOperator.java.
|
staticprotected |
Definition at line 42 of file PathOperator.java.
void com.google.ortools.constraintsolver.PathOperator.swigReleaseOwnership | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 75 of file PathOperator.java.
void com.google.ortools.constraintsolver.PathOperator.swigTakeOwnership | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.IntVarLocalSearchOperator.
Definition at line 80 of file PathOperator.java.