![]() |
Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
|
A sequence variable is a variable whose domain is a set of possible
orderings of the interval variables. It allows ordering of tasks. It
has two sets of methods: ComputePossibleFirstsAndLasts(), which
returns the list of interval variables that can be ranked first or
last; and RankFirst/RankNotFirst/RankLast/RankNotLast, which can be
used to create the search decision.
Definition at line 19 of file SequenceVar.java.
Public Member Functions | |
| SequenceVar (long cPtr, boolean cMemoryOwn) | |
| synchronized void | delete () |
| SequenceVar (Solver s, IntervalVar[] intervals, IntVar[] nexts, String name) | |
| String | toString () |
| void | rankFirst (int index) |
| void | rankNotFirst (int index) |
| void | rankLast (int index) |
| void | rankNotLast (int index) |
| void | rankSequence (int[] rank_first, int[] rank_last, int[] unperformed) |
| IntervalVar | interval (int index) |
| IntVar | next (int index) |
| long | size () |
| void | accept (ModelVisitor visitor) |
| Public Member Functions inherited from com.google.ortools.constraintsolver.PropagationBaseObject | |
| PropagationBaseObject (long cPtr, boolean cMemoryOwn) | |
| PropagationBaseObject (Solver s) | |
| Solver | solver () |
| void | freezeQueue () |
| void | unfreezeQueue () |
| void | enqueueDelayedDemon (Demon d) |
| void | enqueueVar (Demon d) |
| void | reset_action_on_fail () |
| void | set_variable_to_clean_on_fail (IntVar v) |
| String | name () |
| void | setName (String name) |
| boolean | hasName () |
| String | baseName () |
| Public Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
| BaseObject (long cPtr, boolean cMemoryOwn) | |
| BaseObject () | |
Static Public Member Functions | |
| static long | getCPtr (SequenceVar obj) |
| static long | swigRelease (SequenceVar obj) |
| Static Public Member Functions inherited from com.google.ortools.constraintsolver.PropagationBaseObject | |
| static long | getCPtr (PropagationBaseObject obj) |
| static long | swigRelease (PropagationBaseObject obj) |
| Static Public Member Functions inherited from com.google.ortools.constraintsolver.BaseObject | |
| static long | getCPtr (BaseObject obj) |
| static long | swigRelease (BaseObject obj) |
Protected Member Functions | |
| void | finalize () |
Additional Inherited Members | |
| Protected Attributes inherited from com.google.ortools.constraintsolver.BaseObject | |
| transient boolean | swigCMemOwn |
| com.google.ortools.constraintsolver.SequenceVar.SequenceVar | ( | long | cPtr, |
| boolean | cMemoryOwn ) |
Definition at line 22 of file SequenceVar.java.
| com.google.ortools.constraintsolver.SequenceVar.SequenceVar | ( | Solver | s, |
| IntervalVar[] | intervals, | ||
| IntVar[] | nexts, | ||
| String | name ) |
Definition at line 59 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.accept | ( | ModelVisitor | visitor | ) |
Accepts the given visitor.
Definition at line 136 of file SequenceVar.java.
| synchronized void com.google.ortools.constraintsolver.SequenceVar.delete | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.
Definition at line 48 of file SequenceVar.java.
|
protected |
Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.
Definition at line 44 of file SequenceVar.java.
|
static |
Definition at line 27 of file SequenceVar.java.
| IntervalVar com.google.ortools.constraintsolver.SequenceVar.interval | ( | int | index | ) |
Returns the index_th interval of the sequence.
Definition at line 113 of file SequenceVar.java.
| IntVar com.google.ortools.constraintsolver.SequenceVar.next | ( | int | index | ) |
Returns the next of the index_th interval of the sequence.
Definition at line 121 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.rankFirst | ( | int | index | ) |
Ranks the index_th interval var first of all unranked interval
vars. After that, it will no longer be considered ranked.
Definition at line 71 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.rankLast | ( | int | index | ) |
Ranks the index_th interval var first of all unranked interval
vars. After that, it will no longer be considered ranked.
Definition at line 87 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.rankNotFirst | ( | int | index | ) |
Indicates that the index_th interval var will not be ranked first
of all currently unranked interval vars.
Definition at line 79 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.rankNotLast | ( | int | index | ) |
Indicates that the index_th interval var will not be ranked first
of all currently unranked interval vars.
Definition at line 95 of file SequenceVar.java.
| void com.google.ortools.constraintsolver.SequenceVar.rankSequence | ( | int[] | rank_first, |
| int[] | rank_last, | ||
| int[] | unperformed ) |
Applies the following sequence of ranks, ranks first, then rank
last. rank_first and rank_last represents different directions.
rank_first[0] corresponds to the first interval of the sequence.
rank_last[0] corresponds to the last interval of the sequence.
All intervals in the unperformed vector will be marked as such.
Definition at line 106 of file SequenceVar.java.
| long com.google.ortools.constraintsolver.SequenceVar.size | ( | ) |
Returns the number of interval vars in the sequence.
Definition at line 129 of file SequenceVar.java.
|
static |
Definition at line 31 of file SequenceVar.java.
| String com.google.ortools.constraintsolver.SequenceVar.toString | ( | ) |
Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.
Definition at line 63 of file SequenceVar.java.