Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
Public Member Functions | |
Builder | clear () |
com.google.protobuf.Descriptors.Descriptor | getDescriptorForType () |
com.google.ortools.sat.LinearBooleanConstraint | getDefaultInstanceForType () |
com.google.ortools.sat.LinearBooleanConstraint | build () |
com.google.ortools.sat.LinearBooleanConstraint | buildPartial () |
Builder | mergeFrom (com.google.protobuf.Message other) |
Builder | mergeFrom (com.google.ortools.sat.LinearBooleanConstraint other) |
final boolean | isInitialized () |
Builder | mergeFrom (com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException |
java.util.List< java.lang.Integer > | getLiteralsList () |
int | getLiteralsCount () |
int | getLiterals (int index) |
Builder | setLiterals (int index, int value) |
Builder | addLiterals (int value) |
Builder | addAllLiterals (java.lang.Iterable<? extends java.lang.Integer > values) |
Builder | clearLiterals () |
java.util.List< java.lang.Long > | getCoefficientsList () |
int | getCoefficientsCount () |
long | getCoefficients (int index) |
Builder | setCoefficients (int index, long value) |
Builder | addCoefficients (long value) |
Builder | addAllCoefficients (java.lang.Iterable<? extends java.lang.Long > values) |
Builder | clearCoefficients () |
boolean | hasLowerBound () |
long | getLowerBound () |
Builder | setLowerBound (long value) |
Builder | clearLowerBound () |
boolean | hasUpperBound () |
long | getUpperBound () |
Builder | setUpperBound (long value) |
Builder | clearUpperBound () |
boolean | hasName () |
java.lang.String | getName () |
com.google.protobuf.ByteString | getNameBytes () |
Builder | setName (java.lang.String value) |
Builder | clearName () |
Builder | setNameBytes (com.google.protobuf.ByteString value) |
Public Member Functions inherited from com.google.ortools.sat.LinearBooleanConstraintOrBuilder |
Static Public Member Functions | |
static final com.google.protobuf.Descriptors.Descriptor | getDescriptor () |
Protected Member Functions | |
com.google.protobuf.GeneratedMessage.FieldAccessorTable | internalGetFieldAccessorTable () |
A linear Boolean constraint which is a bounded sum of linear terms. Each term beeing a literal times an integer coefficient. If we assume that a literal takes the value 1 if it is true and 0 otherwise, the constraint is: lower_bound <= ... + coefficients[i] * literals[i] + ... <= upper_bound
Protobuf type operations_research.sat.LinearBooleanConstraint
Definition at line 501 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.addAllCoefficients | ( | java.lang.Iterable<? extends java.lang.Long > | values | ) |
repeated int64 coefficients = 2;
values | The coefficients to add. |
Definition at line 961 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.addAllLiterals | ( | java.lang.Iterable<? extends java.lang.Integer > | values | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
values | The literals to add. |
Definition at line 865 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.addCoefficients | ( | long | value | ) |
repeated int64 coefficients = 2;
value | The coefficients to add. |
Definition at line 948 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.addLiterals | ( | int | value | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
value | The literals to add. |
Definition at line 840 of file LinearBooleanConstraint.java.
com.google.ortools.sat.LinearBooleanConstraint com.google.ortools.sat.LinearBooleanConstraint.Builder.build | ( | ) |
Definition at line 552 of file LinearBooleanConstraint.java.
com.google.ortools.sat.LinearBooleanConstraint com.google.ortools.sat.LinearBooleanConstraint.Builder.buildPartial | ( | ) |
Definition at line 561 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clear | ( | ) |
Definition at line 529 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clearCoefficients | ( | ) |
repeated int64 coefficients = 2;
Definition at line 974 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clearLiterals | ( | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
Definition at line 890 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clearLowerBound | ( | ) |
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;
Definition at line 1038 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clearName | ( | ) |
The name of this constraint.
optional string name = 5 [default = ""];
Definition at line 1165 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.clearUpperBound | ( | ) |
optional int64 upper_bound = 4;
Definition at line 1078 of file LinearBooleanConstraint.java.
long com.google.ortools.sat.LinearBooleanConstraint.Builder.getCoefficients | ( | int | index | ) |
repeated int64 coefficients = 2;
index | The index of the element to return. |
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 925 of file LinearBooleanConstraint.java.
int com.google.ortools.sat.LinearBooleanConstraint.Builder.getCoefficientsCount | ( | ) |
repeated int64 coefficients = 2;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 917 of file LinearBooleanConstraint.java.
java.util.List< java.lang.Long > com.google.ortools.sat.LinearBooleanConstraint.Builder.getCoefficientsList | ( | ) |
repeated int64 coefficients = 2;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 909 of file LinearBooleanConstraint.java.
com.google.ortools.sat.LinearBooleanConstraint com.google.ortools.sat.LinearBooleanConstraint.Builder.getDefaultInstanceForType | ( | ) |
Definition at line 547 of file LinearBooleanConstraint.java.
|
static |
Definition at line 506 of file LinearBooleanConstraint.java.
com.google.protobuf.Descriptors.Descriptor com.google.ortools.sat.LinearBooleanConstraint.Builder.getDescriptorForType | ( | ) |
Definition at line 542 of file LinearBooleanConstraint.java.
int com.google.ortools.sat.LinearBooleanConstraint.Builder.getLiterals | ( | int | index | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
index | The index of the element to return. |
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 793 of file LinearBooleanConstraint.java.
int com.google.ortools.sat.LinearBooleanConstraint.Builder.getLiteralsCount | ( | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 773 of file LinearBooleanConstraint.java.
java.util.List< java.lang.Integer > com.google.ortools.sat.LinearBooleanConstraint.Builder.getLiteralsList | ( | ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 753 of file LinearBooleanConstraint.java.
long com.google.ortools.sat.LinearBooleanConstraint.Builder.getLowerBound | ( | ) |
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1007 of file LinearBooleanConstraint.java.
java.lang.String com.google.ortools.sat.LinearBooleanConstraint.Builder.getName | ( | ) |
The name of this constraint.
optional string name = 5 [default = ""];
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1105 of file LinearBooleanConstraint.java.
com.google.protobuf.ByteString com.google.ortools.sat.LinearBooleanConstraint.Builder.getNameBytes | ( | ) |
The name of this constraint.
optional string name = 5 [default = ""];
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1128 of file LinearBooleanConstraint.java.
long com.google.ortools.sat.LinearBooleanConstraint.Builder.getUpperBound | ( | ) |
optional int64 upper_bound = 4;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1059 of file LinearBooleanConstraint.java.
boolean com.google.ortools.sat.LinearBooleanConstraint.Builder.hasLowerBound | ( | ) |
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 993 of file LinearBooleanConstraint.java.
boolean com.google.ortools.sat.LinearBooleanConstraint.Builder.hasName | ( | ) |
The name of this constraint.
optional string name = 5 [default = ""];
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1094 of file LinearBooleanConstraint.java.
boolean com.google.ortools.sat.LinearBooleanConstraint.Builder.hasUpperBound | ( | ) |
optional int64 upper_bound = 4;
Implements com.google.ortools.sat.LinearBooleanConstraintOrBuilder.
Definition at line 1051 of file LinearBooleanConstraint.java.
|
protected |
Definition at line 512 of file LinearBooleanConstraint.java.
final boolean com.google.ortools.sat.LinearBooleanConstraint.Builder.isInitialized | ( | ) |
Definition at line 645 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.mergeFrom | ( | com.google.ortools.sat.LinearBooleanConstraint | other | ) |
Definition at line 604 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.mergeFrom | ( | com.google.protobuf.CodedInputStream | input, |
com.google.protobuf.ExtensionRegistryLite | extensionRegistry ) throws java.io.IOException |
Definition at line 650 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.mergeFrom | ( | com.google.protobuf.Message | other | ) |
Definition at line 595 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setCoefficients | ( | int | index, |
long | value ) |
repeated int64 coefficients = 2;
index | The index to set the value at. |
value | The coefficients to set. |
Definition at line 934 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setLiterals | ( | int | index, |
int | value ) |
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;
index | The index to set the value at. |
value | The literals to set. |
Definition at line 814 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setLowerBound | ( | long | value | ) |
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;
value | The lowerBound to set. |
Definition at line 1021 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setName | ( | java.lang.String | value | ) |
The name of this constraint.
optional string name = 5 [default = ""];
value | The name to set. |
Definition at line 1149 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setNameBytes | ( | com.google.protobuf.ByteString | value | ) |
The name of this constraint.
optional string name = 5 [default = ""];
value | The bytes for name to set. |
Definition at line 1180 of file LinearBooleanConstraint.java.
Builder com.google.ortools.sat.LinearBooleanConstraint.Builder.setUpperBound | ( | long | value | ) |
optional int64 upper_bound = 4;
value | The upperBound to set. |
Definition at line 1067 of file LinearBooleanConstraint.java.