public class PathOperator extends IntVarLocalSearchOperator
swigCMemOwn| Modifier | Constructor and Description |
|---|---|
|
PathOperator(IntVar[] next_vars,
IntVar[] path_vars,
int number_of_base_nodes,
boolean skip_locally_optimal_paths,
boolean accept_path_end_base,
java.util.function.LongToIntFunction start_empty_path_class,
SWIGTYPE_p_std__functionT_std__vectorT_int_t_const_Rfint_intF_t get_neighbors) |
|
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.
|
protected |
PathOperator(long cPtr,
boolean cMemoryOwn) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
ConsiderAlternatives(long base_index)
Indicates if alternatives should be considered when iterating over base
nodes. |
void |
delete() |
protected void |
finalize() |
protected long |
getBaseNodeRestartPosition(int base_index)
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. |
protected static long |
getCPtr(PathOperator obj) |
protected boolean |
initPosition()
Returns true if the operator needs to restart its initial position at each
call to Start() |
boolean |
neighbor() |
protected boolean |
oneNeighbor()
This method should not be overridden.
|
protected void |
OnNodeInitialization()
Called by OnStart() after initializing node information.
|
protected boolean |
onSamePathAsPreviousBase(long base_index)
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. |
long |
Prev(long node)
Returns the node before node in the current delta.
|
void |
reset() |
protected boolean |
restartAtPathStartOnSynchronize()
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. |
protected void |
setNextBaseToIncrement(long base_index)
Set the next base to increment on next iteration.
|
protected void |
swigDirectorDisconnect() |
protected static long |
swigRelease(PathOperator obj) |
void |
swigReleaseOwnership() |
void |
swigTakeOwnership() |
activate, activated, addVars, ApplyChanges, deactivate, getCPtr, HoldsDelta, isIncremental, oldValue, onStart, PrevValue, RevertChanges, setValue, size, SkipUnchanged, start, swigRelease, value, vargetCPtr, HasFragments, nextNeighbor, swigReleasegetCPtr, swigRelease, toStringprotected PathOperator(long cPtr,
boolean cMemoryOwn)
public PathOperator(IntVar[] next_vars, IntVar[] path_vars, SWIGTYPE_p_operations_research__PathOperator__IterationParameters iteration_parameters)
public PathOperator(IntVar[] next_vars, IntVar[] path_vars, int number_of_base_nodes, boolean skip_locally_optimal_paths, boolean accept_path_end_base, java.util.function.LongToIntFunction start_empty_path_class, SWIGTYPE_p_std__functionT_std__vectorT_int_t_const_Rfint_intF_t get_neighbors)
protected static long getCPtr(PathOperator obj)
protected static long swigRelease(PathOperator obj)
protected void finalize()
finalize in class IntVarLocalSearchOperatorpublic void delete()
delete in class IntVarLocalSearchOperatorprotected void swigDirectorDisconnect()
swigDirectorDisconnect in class IntVarLocalSearchOperatorpublic void swigReleaseOwnership()
swigReleaseOwnership in class IntVarLocalSearchOperatorpublic void swigTakeOwnership()
swigTakeOwnership in class IntVarLocalSearchOperatorpublic boolean neighbor()
public void reset()
reset in class LocalSearchOperatorpublic long Prev(long node)
protected boolean oneNeighbor()
oneNeighbor in class IntVarLocalSearchOperatorprotected void OnNodeInitialization()
protected boolean restartAtPathStartOnSynchronize()
protected boolean onSamePathAsPreviousBase(long base_index)
protected long getBaseNodeRestartPosition(int base_index)
protected void setNextBaseToIncrement(long base_index)
protected boolean ConsiderAlternatives(long base_index)
protected boolean initPosition()
Copyright © 2024. All rights reserved.