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

Public Member Functions

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 (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 ()
 

Protected Member Functions

 SequenceVar (long cPtr, boolean cMemoryOwn)
 
void finalize ()
 
- Protected Member Functions inherited from com.google.ortools.constraintsolver.PropagationBaseObject
 PropagationBaseObject (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 (SequenceVar obj)
 
static long swigRelease (SequenceVar obj)
 
- Static Protected Member Functions inherited from com.google.ortools.constraintsolver.PropagationBaseObject
static long getCPtr (PropagationBaseObject obj)
 
static long swigRelease (PropagationBaseObject 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

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.

Constructor & Destructor Documentation

◆ SequenceVar() [1/2]

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

Definition at line 22 of file SequenceVar.java.

◆ SequenceVar() [2/2]

com.google.ortools.constraintsolver.SequenceVar.SequenceVar ( Solver s,
IntervalVar[] intervals,
IntVar[] nexts,
String name )

Definition at line 59 of file SequenceVar.java.

Member Function Documentation

◆ accept()

void com.google.ortools.constraintsolver.SequenceVar.accept ( ModelVisitor visitor)

Accepts the given visitor.

Definition at line 136 of file SequenceVar.java.

◆ delete()

synchronized void com.google.ortools.constraintsolver.SequenceVar.delete ( )

Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.

Definition at line 48 of file SequenceVar.java.

◆ finalize()

void com.google.ortools.constraintsolver.SequenceVar.finalize ( )
protected

Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.

Definition at line 44 of file SequenceVar.java.

◆ getCPtr()

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

Definition at line 27 of file SequenceVar.java.

◆ interval()

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.

◆ next()

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.

◆ rankFirst()

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.

◆ rankLast()

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.

◆ rankNotFirst()

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.

◆ rankNotLast()

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.

◆ rankSequence()

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.

◆ size()

long com.google.ortools.constraintsolver.SequenceVar.size ( )

Returns the number of interval vars in the sequence.

Definition at line 129 of file SequenceVar.java.

◆ swigRelease()

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

Definition at line 31 of file SequenceVar.java.

◆ toString()

String com.google.ortools.constraintsolver.SequenceVar.toString ( )

Reimplemented from com.google.ortools.constraintsolver.PropagationBaseObject.

Definition at line 63 of file SequenceVar.java.


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