Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
com.google.ortools.sat.ReservoirConstraint Class Reference
Inheritance diagram for com.google.ortools.sat.ReservoirConstraint:
com.google.ortools.sat.Constraint com.google.ortools.sat.Constraint

Public Member Functions

 ReservoirConstraint (CpModel model)
 
ReservoirConstraint addEvent (LinearArgument time, long levelChange)
 
ReservoirConstraint addEvent (long time, long levelChange)
 
ReservoirConstraint addOptionalEvent (LinearExpr time, long levelChange, Literal isActive)
 
ReservoirConstraint addOptionalEvent (long time, long levelChange, Literal isActive)
 
 ReservoirConstraint (CpModel model)
 
ReservoirConstraint addEvent (LinearArgument time, long levelChange)
 
ReservoirConstraint addEvent (long time, long levelChange)
 
ReservoirConstraint addOptionalEvent (LinearExpr time, long levelChange, Literal isActive)
 
ReservoirConstraint addOptionalEvent (long time, long levelChange, Literal isActive)
 
- Public Member Functions inherited from com.google.ortools.sat.Constraint
 Constraint (CpModelProto.Builder builder)
 
void onlyEnforceIf (Literal lit)
 
void onlyEnforceIf (Literal[] lits)
 
int getIndex ()
 
ConstraintProto.Builder getBuilder ()
 
 Constraint (CpModelProto.Builder builder)
 
void onlyEnforceIf (Literal lit)
 
void onlyEnforceIf (Literal[] lits)
 
int getIndex ()
 
ConstraintProto.Builder getBuilder ()
 

Detailed Description

Specialized reservoir constraint.

This constraint allows adding events (time, levelChange, isActive (optional)) to the reservoir constraint incrementally.

Definition at line 24 of file ReservoirConstraint.java.

Constructor & Destructor Documentation

◆ ReservoirConstraint() [1/2]

com.google.ortools.sat.ReservoirConstraint.ReservoirConstraint ( CpModel model)

Definition at line 25 of file ReservoirConstraint.java.

◆ ReservoirConstraint() [2/2]

com.google.ortools.sat.ReservoirConstraint.ReservoirConstraint ( CpModel model)

Definition at line 25 of file ReservoirConstraint.java.

Member Function Documentation

◆ addEvent() [1/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addEvent ( LinearArgument time,
long levelChange )

Adds a mandatory event

It will increase the used capacity by levelChange at time time. time must be an affine expression.

Definition at line 36 of file ReservoirConstraint.java.

◆ addEvent() [2/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addEvent ( LinearArgument time,
long levelChange )

Adds a mandatory event

It will increase the used capacity by levelChange at time time. time must be an affine expression.

Definition at line 36 of file ReservoirConstraint.java.

◆ addEvent() [3/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addEvent ( long time,
long levelChange )

Adds a mandatory event at a fixed time

It will increase the used capacity by levelChange at time time.

Definition at line 50 of file ReservoirConstraint.java.

◆ addEvent() [4/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addEvent ( long time,
long levelChange )

Adds a mandatory event at a fixed time

It will increase the used capacity by levelChange at time time.

Definition at line 50 of file ReservoirConstraint.java.

◆ addOptionalEvent() [1/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addOptionalEvent ( LinearExpr time,
long levelChange,
Literal isActive )

Adds an optional event

If isActive is true, It will increase the used capacity by levelChange at time time. time must be an affine expression.

Definition at line 64 of file ReservoirConstraint.java.

◆ addOptionalEvent() [2/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addOptionalEvent ( LinearExpr time,
long levelChange,
Literal isActive )

Adds an optional event

If isActive is true, It will increase the used capacity by levelChange at time time. time must be an affine expression.

Definition at line 64 of file ReservoirConstraint.java.

◆ addOptionalEvent() [3/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addOptionalEvent ( long time,
long levelChange,
Literal isActive )

Adds an optional event at a fixed time

If isActive is true, It will increase the used capacity by levelChange at time time.

Definition at line 78 of file ReservoirConstraint.java.

◆ addOptionalEvent() [4/4]

ReservoirConstraint com.google.ortools.sat.ReservoirConstraint.addOptionalEvent ( long time,
long levelChange,
Literal isActive )

Adds an optional event at a fixed time

If isActive is true, It will increase the used capacity by levelChange at time time.

Definition at line 78 of file ReservoirConstraint.java.


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