Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
Public Member Functions | |
synchronized void | delete () |
void | init () |
boolean | ok () |
long | value () |
void | next () |
String | toString () |
Public Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
BaseObject () | |
Protected Member Functions | |
IntVarIterator (long cPtr, boolean cMemoryOwn) | |
void | finalize () |
Protected Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
BaseObject (long cPtr, boolean cMemoryOwn) | |
Static Protected Member Functions | |
static long | getCPtr (IntVarIterator obj) |
static long | swigRelease (IntVarIterator 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 |
The class Iterator has two direct subclasses. HoleIterators
iterates over all holes, that is value removed between the
current min and max of the variable since the last time the
variable was processed in the queue. DomainIterators iterates
over all elements of the variable domain. Both iterators are not
robust to domain changes. Hole iterators can also report values outside
the current min and max of the variable.
HoleIterators should only be called from a demon attached to the
variable that has created this iterator.
IntVar* current_var;
std::unique_ptr<IntVarIterator> it(current_var->MakeHoleIterator(false));
for (const int64_t hole : InitAndGetValues(it)) {
use the hole
}
Definition at line 27 of file IntVarIterator.java.
|
protected |
Definition at line 30 of file IntVarIterator.java.
synchronized void com.google.ortools.constraintsolver.IntVarIterator.delete | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.BaseObject.
Definition at line 56 of file IntVarIterator.java.
|
protected |
Reimplemented from com.google.ortools.constraintsolver.BaseObject.
Definition at line 52 of file IntVarIterator.java.
|
staticprotected |
Definition at line 35 of file IntVarIterator.java.
void com.google.ortools.constraintsolver.IntVarIterator.init | ( | ) |
This method must be called before each loop.
Definition at line 70 of file IntVarIterator.java.
void com.google.ortools.constraintsolver.IntVarIterator.next | ( | ) |
This method moves the iterator to the next value.
Definition at line 91 of file IntVarIterator.java.
boolean com.google.ortools.constraintsolver.IntVarIterator.ok | ( | ) |
This method indicates if we can call Value() or not.
Definition at line 77 of file IntVarIterator.java.
|
staticprotected |
Definition at line 39 of file IntVarIterator.java.
String com.google.ortools.constraintsolver.IntVarIterator.toString | ( | ) |
Pretty Print.
Reimplemented from com.google.ortools.constraintsolver.BaseObject.
Definition at line 98 of file IntVarIterator.java.
long com.google.ortools.constraintsolver.IntVarIterator.value | ( | ) |
This method returns the current value of the iterator.
Definition at line 84 of file IntVarIterator.java.