Google OR-Tools v9.9
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
com.google.ortools.constraintsolver.LocalSearchOperator Class Reference
Inheritance diagram for com.google.ortools.constraintsolver.LocalSearchOperator:
com.google.ortools.constraintsolver.BaseObject com.google.ortools.constraintsolver.IntVarLocalSearchOperator com.google.ortools.constraintsolver.BaseLns com.google.ortools.constraintsolver.ChangeValue com.google.ortools.constraintsolver.PathOperator

Public Member Functions

synchronized void delete ()
 
void swigReleaseOwnership ()
 
void swigTakeOwnership ()
 
 LocalSearchOperator ()
 
boolean nextNeighbor (Assignment delta, Assignment deltadelta)
 
void start (Assignment assignment)
 
void reset ()
 
boolean HasFragments ()
 
boolean HoldsDelta ()
 
- Public Member Functions inherited from com.google.ortools.constraintsolver.BaseObject
 BaseObject ()
 
String toString ()
 

Protected Member Functions

 LocalSearchOperator (long cPtr, boolean cMemoryOwn)
 
void finalize ()
 
void swigDirectorDisconnect ()
 
- Protected Member Functions inherited from com.google.ortools.constraintsolver.BaseObject
 BaseObject (long cPtr, boolean cMemoryOwn)
 

Static Protected Member Functions

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
 

Detailed Description

The base class for all local search operators.

A local search operator is an object that defines the neighborhood of a
solution. In other words, a neighborhood is the set of solutions which can
be reached from a given solution using an operator.

The behavior of the LocalSearchOperator class is similar to iterators.
The operator is synchronized with an assignment (gives the
current values of the variables); this is done in the Start() method.

Then one can iterate over the neighbors using the MakeNextNeighbor method.
This method returns an assignment which represents the incremental changes
to the current solution. It also returns a second assignment representing
the changes to the last solution defined by the neighborhood operator; this
assignment is empty if the neighborhood operator cannot track this
information.

Definition at line 29 of file LocalSearchOperator.java.

Constructor & Destructor Documentation

◆ LocalSearchOperator() [1/2]

com.google.ortools.constraintsolver.LocalSearchOperator.LocalSearchOperator ( long cPtr,
boolean cMemoryOwn )
protected

Definition at line 32 of file LocalSearchOperator.java.

◆ LocalSearchOperator() [2/2]

com.google.ortools.constraintsolver.LocalSearchOperator.LocalSearchOperator ( )

Definition at line 84 of file LocalSearchOperator.java.

Member Function Documentation

◆ delete()

◆ finalize()

◆ getCPtr()

static long com.google.ortools.constraintsolver.LocalSearchOperator.getCPtr ( LocalSearchOperator obj)
staticprotected

Definition at line 37 of file LocalSearchOperator.java.

◆ HasFragments()

boolean com.google.ortools.constraintsolver.LocalSearchOperator.HasFragments ( )

Reimplemented in com.google.ortools.constraintsolver.BaseLns.

Definition at line 101 of file LocalSearchOperator.java.

◆ HoldsDelta()

boolean com.google.ortools.constraintsolver.LocalSearchOperator.HoldsDelta ( )

◆ nextNeighbor()

boolean com.google.ortools.constraintsolver.LocalSearchOperator.nextNeighbor ( Assignment delta,
Assignment deltadelta )

Definition at line 89 of file LocalSearchOperator.java.

◆ reset()

void com.google.ortools.constraintsolver.LocalSearchOperator.reset ( )

Reimplemented in com.google.ortools.constraintsolver.PathOperator.

Definition at line 97 of file LocalSearchOperator.java.

◆ start()

void com.google.ortools.constraintsolver.LocalSearchOperator.start ( Assignment assignment)

◆ swigDirectorDisconnect()

void com.google.ortools.constraintsolver.LocalSearchOperator.swigDirectorDisconnect ( )
protected

◆ swigRelease()

static long com.google.ortools.constraintsolver.LocalSearchOperator.swigRelease ( LocalSearchOperator obj)
staticprotected

Definition at line 41 of file LocalSearchOperator.java.

◆ swigReleaseOwnership()

◆ swigTakeOwnership()


The documentation for this class was generated from the following file: