Java Reference
Java Reference
Detailed Description
The response returned by a solver trying to solve a CpModelProto. TODO(user): support returning multiple solutions. Look at the Stubby streaming API as we probably wants to get them as they are found. Next id: 24
Protobuf type
Definition at line 1260 of file CpSolverResponse.java.
Public Member Functions | |
| .lang.Override Builder | clear () |
| .lang.Override com.google.protobuf.Descriptors.Descriptor | getDescriptorForType () |
| .lang.Override com.google.ortools.sat.CpSolverResponse | getDefaultInstanceForType () |
| .lang.Override com.google.ortools.sat.CpSolverResponse | build () |
| .lang.Override com.google.ortools.sat.CpSolverResponse | buildPartial () |
| .lang.Override Builder | clone () |
| .lang.Override Builder | setField (com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) |
| .lang.Override Builder | clearField (com.google.protobuf.Descriptors.FieldDescriptor field) |
| .lang.Override Builder | clearOneof (com.google.protobuf.Descriptors.OneofDescriptor oneof) |
| .lang.Override Builder | setRepeatedField (com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) |
| .lang.Override Builder | addRepeatedField (com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) |
| .lang.Override Builder | mergeFrom (com.google.protobuf.Message other) |
| Builder | mergeFrom (com.google.ortools.sat.CpSolverResponse other) |
| .lang.Override final boolean | isInitialized () |
| .lang.Override Builder | mergeFrom (com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException |
| .lang.Override int | getStatusValue () |
| Builder | setStatusValue (int value) |
| .lang.Override com.google.ortools.sat.CpSolverStatus | getStatus () |
| Builder | setStatus (com.google.ortools.sat.CpSolverStatus value) |
| Builder | clearStatus () |
| java.util.List< java.lang.Long > | getSolutionList () |
| int | getSolutionCount () |
| long | getSolution (int index) |
| Builder | setSolution (int index, long value) |
| Builder | addSolution (long value) |
| Builder | addAllSolution (java.lang.Iterable<? extends java.lang.Long > values) |
| Builder | clearSolution () |
| .lang.Override double | getObjectiveValue () |
| Builder | setObjectiveValue (double value) |
| Builder | clearObjectiveValue () |
| .lang.Override double | getBestObjectiveBound () |
| Builder | setBestObjectiveBound (double value) |
| Builder | clearBestObjectiveBound () |
| java.util.List< java.lang.Long > | getSolutionLowerBoundsList () |
| int | getSolutionLowerBoundsCount () |
| long | getSolutionLowerBounds (int index) |
| Builder | setSolutionLowerBounds (int index, long value) |
| Builder | addSolutionLowerBounds (long value) |
| Builder | addAllSolutionLowerBounds (java.lang.Iterable<? extends java.lang.Long > values) |
| Builder | clearSolutionLowerBounds () |
| java.util.List< java.lang.Long > | getSolutionUpperBoundsList () |
repeated int64 solution_upper_bounds = 19; More... | |
| int | getSolutionUpperBoundsCount () |
repeated int64 solution_upper_bounds = 19; More... | |
| long | getSolutionUpperBounds (int index) |
repeated int64 solution_upper_bounds = 19; More... | |
| Builder | setSolutionUpperBounds (int index, long value) |
repeated int64 solution_upper_bounds = 19; More... | |
| Builder | addSolutionUpperBounds (long value) |
repeated int64 solution_upper_bounds = 19; More... | |
| Builder | addAllSolutionUpperBounds (java.lang.Iterable<? extends java.lang.Long > values) |
repeated int64 solution_upper_bounds = 19; More... | |
| Builder | clearSolutionUpperBounds () |
repeated int64 solution_upper_bounds = 19; More... | |
| java.util.List< com.google.ortools.sat.IntegerVariableProto > | getTightenedVariablesList () |
| int | getTightenedVariablesCount () |
| com.google.ortools.sat.IntegerVariableProto | getTightenedVariables (int index) |
| Builder | setTightenedVariables (int index, com.google.ortools.sat.IntegerVariableProto value) |
| Builder | setTightenedVariables (int index, com.google.ortools.sat.IntegerVariableProto.Builder builderForValue) |
| Builder | addTightenedVariables (com.google.ortools.sat.IntegerVariableProto value) |
| Builder | addTightenedVariables (int index, com.google.ortools.sat.IntegerVariableProto value) |
| Builder | addTightenedVariables (com.google.ortools.sat.IntegerVariableProto.Builder builderForValue) |
| Builder | addTightenedVariables (int index, com.google.ortools.sat.IntegerVariableProto.Builder builderForValue) |
| Builder | addAllTightenedVariables (java.lang.Iterable<? extends com.google.ortools.sat.IntegerVariableProto > values) |
| Builder | clearTightenedVariables () |
| Builder | removeTightenedVariables (int index) |
| com.google.ortools.sat.IntegerVariableProto.Builder | getTightenedVariablesBuilder (int index) |
| com.google.ortools.sat.IntegerVariableProtoOrBuilder | getTightenedVariablesOrBuilder (int index) |
| java.util.List<? extends com.google.ortools.sat.IntegerVariableProtoOrBuilder > | getTightenedVariablesOrBuilderList () |
| com.google.ortools.sat.IntegerVariableProto.Builder | addTightenedVariablesBuilder () |
| com.google.ortools.sat.IntegerVariableProto.Builder | addTightenedVariablesBuilder (int index) |
| java.util.List< com.google.ortools.sat.IntegerVariableProto.Builder > | getTightenedVariablesBuilderList () |
| java.util.List< java.lang.Integer > | getSufficientAssumptionsForInfeasibilityList () |
| int | getSufficientAssumptionsForInfeasibilityCount () |
| int | getSufficientAssumptionsForInfeasibility (int index) |
| Builder | setSufficientAssumptionsForInfeasibility (int index, int value) |
| Builder | addSufficientAssumptionsForInfeasibility (int value) |
| Builder | addAllSufficientAssumptionsForInfeasibility (java.lang.Iterable<? extends java.lang.Integer > values) |
| Builder | clearSufficientAssumptionsForInfeasibility () |
| .lang.Override boolean | getAllSolutionsWereFound () |
| Builder | setAllSolutionsWereFound (boolean value) |
| Builder | clearAllSolutionsWereFound () |
| .lang.Override long | getNumBooleans () |
| Builder | setNumBooleans (long value) |
| Builder | clearNumBooleans () |
| .lang.Override long | getNumConflicts () |
int64 num_conflicts = 11; More... | |
| Builder | setNumConflicts (long value) |
int64 num_conflicts = 11; More... | |
| Builder | clearNumConflicts () |
int64 num_conflicts = 11; More... | |
| .lang.Override long | getNumBranches () |
int64 num_branches = 12; More... | |
| Builder | setNumBranches (long value) |
int64 num_branches = 12; More... | |
| Builder | clearNumBranches () |
int64 num_branches = 12; More... | |
| .lang.Override long | getNumBinaryPropagations () |
int64 num_binary_propagations = 13; More... | |
| Builder | setNumBinaryPropagations (long value) |
int64 num_binary_propagations = 13; More... | |
| Builder | clearNumBinaryPropagations () |
int64 num_binary_propagations = 13; More... | |
| .lang.Override long | getNumIntegerPropagations () |
int64 num_integer_propagations = 14; More... | |
| Builder | setNumIntegerPropagations (long value) |
int64 num_integer_propagations = 14; More... | |
| Builder | clearNumIntegerPropagations () |
int64 num_integer_propagations = 14; More... | |
| .lang.Override double | getWallTime () |
double wall_time = 15; More... | |
| Builder | setWallTime (double value) |
double wall_time = 15; More... | |
| Builder | clearWallTime () |
double wall_time = 15; More... | |
| .lang.Override double | getUserTime () |
double user_time = 16; More... | |
| Builder | setUserTime (double value) |
double user_time = 16; More... | |
| Builder | clearUserTime () |
double user_time = 16; More... | |
| .lang.Override double | getDeterministicTime () |
double deterministic_time = 17; More... | |
| Builder | setDeterministicTime (double value) |
double deterministic_time = 17; More... | |
| Builder | clearDeterministicTime () |
double deterministic_time = 17; More... | |
| .lang.Override double | getPrimalIntegral () |
double primal_integral = 22; More... | |
| Builder | setPrimalIntegral (double value) |
double primal_integral = 22; More... | |
| Builder | clearPrimalIntegral () |
double primal_integral = 22; More... | |
| java.lang.String | getSolutionInfo () |
| com.google.protobuf.ByteString | getSolutionInfoBytes () |
| Builder | setSolutionInfo (java.lang.String value) |
| Builder | clearSolutionInfo () |
| Builder | setSolutionInfoBytes (com.google.protobuf.ByteString value) |
| .lang.Override final Builder | setUnknownFields (final com.google.protobuf.UnknownFieldSet unknownFields) |
| .lang.Override final Builder | mergeUnknownFields (final com.google.protobuf.UnknownFieldSet unknownFields) |
Static Public Member Functions | |
| static final com.google.protobuf.Descriptors.Descriptor | getDescriptor () |
Protected Member Functions | |
| .lang.Override com.google.protobuf.GeneratedMessageV3.FieldAccessorTable | internalGetFieldAccessorTable () |
Member Function Documentation
◆ addAllSolution()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Parameters
-
values The solution to add.
- Returns
- This builder for chaining.
Definition at line 1771 of file CpSolverResponse.java.
◆ addAllSolutionLowerBounds()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Parameters
-
values The solutionLowerBounds to add.
- Returns
- This builder for chaining.
Definition at line 2012 of file CpSolverResponse.java.
◆ addAllSolutionUpperBounds()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Parameters
-
values The solutionUpperBounds to add.
- Returns
- This builder for chaining.
Definition at line 2100 of file CpSolverResponse.java.
◆ addAllSufficientAssumptionsForInfeasibility()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Parameters
-
values The sufficientAssumptionsForInfeasibility to add.
- Returns
- This builder for chaining.
Definition at line 2737 of file CpSolverResponse.java.
◆ addAllTightenedVariables()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2386 of file CpSolverResponse.java.
◆ addRepeatedField()
|
inline |
Definition at line 1439 of file CpSolverResponse.java.
◆ addSolution()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Parameters
-
value The solution to add.
- Returns
- This builder for chaining.
Definition at line 1753 of file CpSolverResponse.java.
◆ addSolutionLowerBounds()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Parameters
-
value The solutionLowerBounds to add.
- Returns
- This builder for chaining.
Definition at line 1992 of file CpSolverResponse.java.
◆ addSolutionUpperBounds()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Parameters
-
value The solutionUpperBounds to add.
- Returns
- This builder for chaining.
Definition at line 2089 of file CpSolverResponse.java.
◆ addSufficientAssumptionsForInfeasibility()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Parameters
-
value The sufficientAssumptionsForInfeasibility to add.
- Returns
- This builder for chaining.
Definition at line 2712 of file CpSolverResponse.java.
◆ addTightenedVariables() [1/4]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2273 of file CpSolverResponse.java.
◆ addTightenedVariables() [2/4]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2332 of file CpSolverResponse.java.
◆ addTightenedVariables() [3/4]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2302 of file CpSolverResponse.java.
◆ addTightenedVariables() [4/4]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2359 of file CpSolverResponse.java.
◆ addTightenedVariablesBuilder() [1/2]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2533 of file CpSolverResponse.java.
◆ addTightenedVariablesBuilder() [2/2]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2553 of file CpSolverResponse.java.
◆ build()
|
inline |
Definition at line 1353 of file CpSolverResponse.java.
◆ buildPartial()
|
inline |
Definition at line 1362 of file CpSolverResponse.java.
◆ clear()
|
inline |
Definition at line 1294 of file CpSolverResponse.java.
◆ clearAllSolutionsWereFound()
|
inline |
This will be true iff the solver was asked to find all solutions to a satisfiability problem (or all optimal solutions to an optimization problem), and it was successful in doing so. TODO(user): Remove as we also use the OPTIMAL vs FEASIBLE status for that.
bool all_solutions_were_found = 5;
- Returns
- This builder for chaining.
Definition at line 2815 of file CpSolverResponse.java.
◆ clearBestObjectiveBound()
|
inline |
Only make sense for an optimization problem. A proven lower-bound on the objective for a minimization problem, or a proven upper-bound for a maximization problem.
double best_objective_bound = 4;
- Returns
- This builder for chaining.
Definition at line 1891 of file CpSolverResponse.java.
◆ clearDeterministicTime()
|
inline |
double deterministic_time = 17;
- Returns
- This builder for chaining.
Definition at line 3075 of file CpSolverResponse.java.
◆ clearField()
|
inline |
Definition at line 1423 of file CpSolverResponse.java.
◆ clearNumBinaryPropagations()
|
inline |
int64 num_binary_propagations = 13;
- Returns
- This builder for chaining.
Definition at line 2951 of file CpSolverResponse.java.
◆ clearNumBooleans()
|
inline |
Some statistics about the solve.
int64 num_booleans = 10;
- Returns
- This builder for chaining.
Definition at line 2858 of file CpSolverResponse.java.
◆ clearNumBranches()
|
inline |
int64 num_branches = 12;
- Returns
- This builder for chaining.
Definition at line 2920 of file CpSolverResponse.java.
◆ clearNumConflicts()
|
inline |
int64 num_conflicts = 11;
- Returns
- This builder for chaining.
Definition at line 2889 of file CpSolverResponse.java.
◆ clearNumIntegerPropagations()
|
inline |
int64 num_integer_propagations = 14;
- Returns
- This builder for chaining.
Definition at line 2982 of file CpSolverResponse.java.
◆ clearObjectiveValue()
|
inline |
Only make sense for an optimization problem. The objective value of the returned solution if it is non-empty. If there is no solution, then for a minimization problem, this will be an upper-bound of the objective of any feasible solution, and a lower-bound for a maximization problem.
double objective_value = 3;
- Returns
- This builder for chaining.
Definition at line 1842 of file CpSolverResponse.java.
◆ clearOneof()
|
inline |
Definition at line 1428 of file CpSolverResponse.java.
◆ clearPrimalIntegral()
|
inline |
double primal_integral = 22;
- Returns
- This builder for chaining.
Definition at line 3106 of file CpSolverResponse.java.
◆ clearSolution()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Returns
- This builder for chaining.
Definition at line 1790 of file CpSolverResponse.java.
◆ clearSolutionInfo()
|
inline |
Additional information about how the solution was found.
string solution_info = 20;
- Returns
- This builder for chaining.
Definition at line 3182 of file CpSolverResponse.java.
◆ clearSolutionLowerBounds()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Returns
- This builder for chaining.
Definition at line 2033 of file CpSolverResponse.java.
◆ clearSolutionUpperBounds()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Returns
- This builder for chaining.
Definition at line 2112 of file CpSolverResponse.java.
◆ clearStatus()
|
inline |
The status of the solve.
.operations_research.sat.CpSolverStatus status = 1;
- Returns
- This builder for chaining.
Definition at line 1662 of file CpSolverResponse.java.
◆ clearSufficientAssumptionsForInfeasibility()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Returns
- This builder for chaining.
Definition at line 2763 of file CpSolverResponse.java.
◆ clearTightenedVariables()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2414 of file CpSolverResponse.java.
◆ clearUserTime()
|
inline |
double user_time = 16;
- Returns
- This builder for chaining.
Definition at line 3044 of file CpSolverResponse.java.
◆ clearWallTime()
|
inline |
double wall_time = 15;
- Returns
- This builder for chaining.
Definition at line 3013 of file CpSolverResponse.java.
◆ clone()
|
inline |
Definition at line 1413 of file CpSolverResponse.java.
◆ getAllSolutionsWereFound()
|
inline |
This will be true iff the solver was asked to find all solutions to a satisfiability problem (or all optimal solutions to an optimization problem), and it was successful in doing so. TODO(user): Remove as we also use the OPTIMAL vs FEASIBLE status for that.
bool all_solutions_were_found = 5;
- Returns
- The allSolutionsWereFound.
Implements CpSolverResponseOrBuilder.
Definition at line 2783 of file CpSolverResponse.java.
◆ getBestObjectiveBound()
|
inline |
Only make sense for an optimization problem. A proven lower-bound on the objective for a minimization problem, or a proven upper-bound for a maximization problem.
double best_objective_bound = 4;
- Returns
- The bestObjectiveBound.
Implements CpSolverResponseOrBuilder.
Definition at line 1861 of file CpSolverResponse.java.
◆ getDefaultInstanceForType()
|
inline |
Definition at line 1348 of file CpSolverResponse.java.
◆ getDescriptor()
|
inlinestatic |
Definition at line 1265 of file CpSolverResponse.java.
◆ getDescriptorForType()
|
inline |
Definition at line 1343 of file CpSolverResponse.java.
◆ getDeterministicTime()
|
inline |
double deterministic_time = 17;
- Returns
- The deterministicTime.
Implements CpSolverResponseOrBuilder.
Definition at line 3057 of file CpSolverResponse.java.
◆ getNumBinaryPropagations()
|
inline |
int64 num_binary_propagations = 13;
- Returns
- The numBinaryPropagations.
Implements CpSolverResponseOrBuilder.
Definition at line 2933 of file CpSolverResponse.java.
◆ getNumBooleans()
|
inline |
Some statistics about the solve.
int64 num_booleans = 10;
- Returns
- The numBooleans.
Implements CpSolverResponseOrBuilder.
Definition at line 2832 of file CpSolverResponse.java.
◆ getNumBranches()
|
inline |
int64 num_branches = 12;
- Returns
- The numBranches.
Implements CpSolverResponseOrBuilder.
Definition at line 2902 of file CpSolverResponse.java.
◆ getNumConflicts()
|
inline |
int64 num_conflicts = 11;
- Returns
- The numConflicts.
Implements CpSolverResponseOrBuilder.
Definition at line 2871 of file CpSolverResponse.java.
◆ getNumIntegerPropagations()
|
inline |
int64 num_integer_propagations = 14;
- Returns
- The numIntegerPropagations.
Implements CpSolverResponseOrBuilder.
Definition at line 2964 of file CpSolverResponse.java.
◆ getObjectiveValue()
|
inline |
Only make sense for an optimization problem. The objective value of the returned solution if it is non-empty. If there is no solution, then for a minimization problem, this will be an upper-bound of the objective of any feasible solution, and a lower-bound for a maximization problem.
double objective_value = 3;
- Returns
- The objectiveValue.
Implements CpSolverResponseOrBuilder.
Definition at line 1810 of file CpSolverResponse.java.
◆ getPrimalIntegral()
|
inline |
double primal_integral = 22;
- Returns
- The primalIntegral.
Implements CpSolverResponseOrBuilder.
Definition at line 3088 of file CpSolverResponse.java.
◆ getSolution()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Parameters
-
index The index of the element to return.
- Returns
- The solution at the given index.
Implements CpSolverResponseOrBuilder.
Definition at line 1718 of file CpSolverResponse.java.
◆ getSolutionCount()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Returns
- The count of solution.
Implements CpSolverResponseOrBuilder.
Definition at line 1703 of file CpSolverResponse.java.
◆ getSolutionInfo()
|
inline |
Additional information about how the solution was found.
string solution_info = 20;
- Returns
- The solutionInfo.
Implements CpSolverResponseOrBuilder.
Definition at line 3122 of file CpSolverResponse.java.
◆ getSolutionInfoBytes()
|
inline |
Additional information about how the solution was found.
string solution_info = 20;
- Returns
- The bytes for solutionInfo.
Implements CpSolverResponseOrBuilder.
Definition at line 3143 of file CpSolverResponse.java.
◆ getSolutionList()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Returns
- A list containing the solution.
Implements CpSolverResponseOrBuilder.
Definition at line 1688 of file CpSolverResponse.java.
◆ getSolutionLowerBounds()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Parameters
-
index The index of the element to return.
- Returns
- The solutionLowerBounds at the given index.
Implements CpSolverResponseOrBuilder.
Definition at line 1953 of file CpSolverResponse.java.
◆ getSolutionLowerBoundsCount()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Returns
- The count of solutionLowerBounds.
Implements CpSolverResponseOrBuilder.
Definition at line 1936 of file CpSolverResponse.java.
◆ getSolutionLowerBoundsList()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Returns
- A list containing the solutionLowerBounds.
Implements CpSolverResponseOrBuilder.
Definition at line 1919 of file CpSolverResponse.java.
◆ getSolutionUpperBounds()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Parameters
-
index The index of the element to return.
- Returns
- The solutionUpperBounds at the given index.
Implements CpSolverResponseOrBuilder.
Definition at line 2068 of file CpSolverResponse.java.
◆ getSolutionUpperBoundsCount()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Returns
- The count of solutionUpperBounds.
Implements CpSolverResponseOrBuilder.
Definition at line 2060 of file CpSolverResponse.java.
◆ getSolutionUpperBoundsList()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Returns
- A list containing the solutionUpperBounds.
Implements CpSolverResponseOrBuilder.
Definition at line 2052 of file CpSolverResponse.java.
◆ getStatus()
|
inline |
The status of the solve.
.operations_research.sat.CpSolverStatus status = 1;
- Returns
- The status.
Implements CpSolverResponseOrBuilder.
Definition at line 1631 of file CpSolverResponse.java.
◆ getStatusValue()
|
inline |
The status of the solve.
.operations_research.sat.CpSolverStatus status = 1;
- Returns
- The enum numeric value on the wire for status.
Implements CpSolverResponseOrBuilder.
Definition at line 1604 of file CpSolverResponse.java.
◆ getSufficientAssumptionsForInfeasibility()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Parameters
-
index The index of the element to return.
- Returns
- The sufficientAssumptionsForInfeasibility at the given index.
Implements CpSolverResponseOrBuilder.
Definition at line 2663 of file CpSolverResponse.java.
◆ getSufficientAssumptionsForInfeasibilityCount()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Returns
- The count of sufficientAssumptionsForInfeasibility.
Implements CpSolverResponseOrBuilder.
Definition at line 2641 of file CpSolverResponse.java.
◆ getSufficientAssumptionsForInfeasibilityList()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Returns
- A list containing the sufficientAssumptionsForInfeasibility.
Implements CpSolverResponseOrBuilder.
Definition at line 2619 of file CpSolverResponse.java.
◆ getTightenedVariables()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Implements CpSolverResponseOrBuilder.
Definition at line 2193 of file CpSolverResponse.java.
◆ getTightenedVariablesBuilder()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2466 of file CpSolverResponse.java.
◆ getTightenedVariablesBuilderList()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2575 of file CpSolverResponse.java.
◆ getTightenedVariablesCount()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Implements CpSolverResponseOrBuilder.
Definition at line 2170 of file CpSolverResponse.java.
◆ getTightenedVariablesList()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Implements CpSolverResponseOrBuilder.
Definition at line 2147 of file CpSolverResponse.java.
◆ getTightenedVariablesOrBuilder()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Implements CpSolverResponseOrBuilder.
Definition at line 2486 of file CpSolverResponse.java.
◆ getTightenedVariablesOrBuilderList()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Implements CpSolverResponseOrBuilder.
Definition at line 2510 of file CpSolverResponse.java.
◆ getUserTime()
|
inline |
double user_time = 16;
- Returns
- The userTime.
Implements CpSolverResponseOrBuilder.
Definition at line 3026 of file CpSolverResponse.java.
◆ getWallTime()
|
inline |
double wall_time = 15;
- Returns
- The wallTime.
Implements CpSolverResponseOrBuilder.
Definition at line 2995 of file CpSolverResponse.java.
◆ internalGetFieldAccessorTable()
|
inlineprotected |
Definition at line 1271 of file CpSolverResponse.java.
◆ isInitialized()
|
inline |
Definition at line 1571 of file CpSolverResponse.java.
◆ mergeFrom() [1/3]
|
inline |
Definition at line 1454 of file CpSolverResponse.java.
◆ mergeFrom() [2/3]
|
inline |
Definition at line 1576 of file CpSolverResponse.java.
◆ mergeFrom() [3/3]
|
inline |
Definition at line 1445 of file CpSolverResponse.java.
◆ mergeUnknownFields()
|
inline |
Definition at line 3215 of file CpSolverResponse.java.
◆ removeTightenedVariables()
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2440 of file CpSolverResponse.java.
◆ setAllSolutionsWereFound()
|
inline |
This will be true iff the solver was asked to find all solutions to a satisfiability problem (or all optimal solutions to an optimization problem), and it was successful in doing so. TODO(user): Remove as we also use the OPTIMAL vs FEASIBLE status for that.
bool all_solutions_were_found = 5;
- Parameters
-
value The allSolutionsWereFound to set.
- Returns
- This builder for chaining.
Definition at line 2798 of file CpSolverResponse.java.
◆ setBestObjectiveBound()
|
inline |
Only make sense for an optimization problem. A proven lower-bound on the objective for a minimization problem, or a proven upper-bound for a maximization problem.
double best_objective_bound = 4;
- Parameters
-
value The bestObjectiveBound to set.
- Returns
- This builder for chaining.
Definition at line 1875 of file CpSolverResponse.java.
◆ setDeterministicTime()
|
inline |
double deterministic_time = 17;
- Parameters
-
value The deterministicTime to set.
- Returns
- This builder for chaining.
Definition at line 3065 of file CpSolverResponse.java.
◆ setField()
|
inline |
Definition at line 1417 of file CpSolverResponse.java.
◆ setNumBinaryPropagations()
|
inline |
int64 num_binary_propagations = 13;
- Parameters
-
value The numBinaryPropagations to set.
- Returns
- This builder for chaining.
Definition at line 2941 of file CpSolverResponse.java.
◆ setNumBooleans()
|
inline |
Some statistics about the solve.
int64 num_booleans = 10;
- Parameters
-
value The numBooleans to set.
- Returns
- This builder for chaining.
Definition at line 2844 of file CpSolverResponse.java.
◆ setNumBranches()
|
inline |
int64 num_branches = 12;
- Parameters
-
value The numBranches to set.
- Returns
- This builder for chaining.
Definition at line 2910 of file CpSolverResponse.java.
◆ setNumConflicts()
|
inline |
int64 num_conflicts = 11;
- Parameters
-
value The numConflicts to set.
- Returns
- This builder for chaining.
Definition at line 2879 of file CpSolverResponse.java.
◆ setNumIntegerPropagations()
|
inline |
int64 num_integer_propagations = 14;
- Parameters
-
value The numIntegerPropagations to set.
- Returns
- This builder for chaining.
Definition at line 2972 of file CpSolverResponse.java.
◆ setObjectiveValue()
|
inline |
Only make sense for an optimization problem. The objective value of the returned solution if it is non-empty. If there is no solution, then for a minimization problem, this will be an upper-bound of the objective of any feasible solution, and a lower-bound for a maximization problem.
double objective_value = 3;
- Parameters
-
value The objectiveValue to set.
- Returns
- This builder for chaining.
Definition at line 1825 of file CpSolverResponse.java.
◆ setPrimalIntegral()
|
inline |
double primal_integral = 22;
- Parameters
-
value The primalIntegral to set.
- Returns
- This builder for chaining.
Definition at line 3096 of file CpSolverResponse.java.
◆ setRepeatedField()
|
inline |
Definition at line 1433 of file CpSolverResponse.java.
◆ setSolution()
|
inline |
A feasible solution to the given problem. Depending on the returned status it may be optimal or just feasible. This is in one-to-one correspondence with a CpModelProto::variables repeated field and list the values of all the variables.
repeated int64 solution = 2;
- Parameters
-
index The index to set the value at. value The solution to set.
- Returns
- This builder for chaining.
Definition at line 1734 of file CpSolverResponse.java.
◆ setSolutionInfo()
|
inline |
Additional information about how the solution was found.
string solution_info = 20;
- Parameters
-
value The solutionInfo to set.
- Returns
- This builder for chaining.
Definition at line 3164 of file CpSolverResponse.java.
◆ setSolutionInfoBytes()
|
inline |
Additional information about how the solution was found.
string solution_info = 20;
- Parameters
-
value The bytes for solutionInfo to set.
- Returns
- This builder for chaining.
Definition at line 3197 of file CpSolverResponse.java.
◆ setSolutionLowerBounds()
|
inline |
Advanced usage. If the problem has some variables that are not fixed at the end of the search (because of a particular search strategy in the CpModelProto) then this will be used instead of filling the solution above. The two fields will then contains the lower and upper bounds of each variable as they were when the best "solution" was found.
repeated int64 solution_lower_bounds = 18;
- Parameters
-
index The index to set the value at. value The solutionLowerBounds to set.
- Returns
- This builder for chaining.
Definition at line 1971 of file CpSolverResponse.java.
◆ setSolutionUpperBounds()
|
inline |
repeated int64 solution_upper_bounds = 19;
- Parameters
-
index The index to set the value at. value The solutionUpperBounds to set.
- Returns
- This builder for chaining.
Definition at line 2077 of file CpSolverResponse.java.
◆ setStatus()
|
inline |
The status of the solve.
.operations_research.sat.CpSolverStatus status = 1;
- Parameters
-
value The status to set.
- Returns
- This builder for chaining.
Definition at line 1645 of file CpSolverResponse.java.
◆ setStatusValue()
|
inline |
The status of the solve.
.operations_research.sat.CpSolverStatus status = 1;
- Parameters
-
value The enum numeric value on the wire for status to set.
- Returns
- This builder for chaining.
Definition at line 1616 of file CpSolverResponse.java.
◆ setSufficientAssumptionsForInfeasibility()
|
inline |
A subset of the model "assumptions" field. This will only be filled if the status is INFEASIBLE. This subset of assumption will be enough to still get an infeasible problem. This is related to what is called the irreducible inconsistent subsystem or IIS. Except one is only concerned by the provided assumptions. There is also no guarantee that we return an irreducible (aka minimal subset). However, this is based on SAT explanation and there is a good chance it is not too large. If you really want a minimal subset, a possible way to get one is by changing your model to minimize the number of assumptions at false, but this is likely an harder problem to solve.
repeated int32 sufficient_assumptions_for_infeasibility = 23;
- Parameters
-
index The index to set the value at. value The sufficientAssumptionsForInfeasibility to set.
- Returns
- This builder for chaining.
Definition at line 2686 of file CpSolverResponse.java.
◆ setTightenedVariables() [1/2]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2216 of file CpSolverResponse.java.
◆ setTightenedVariables() [2/2]
|
inline |
Advanced usage. If the option fill_tightened_domains_in_response is set, then this field will be a copy of the CpModelProto.variables where each domain has been reduced using the information the solver was able to derive. Note that this is only filled with the info derived during a normal search and we do not have any dedicated algorithm to improve it. If the problem is a feasibility problem, then these bounds will be valid for any feasible solution. If the problem is an optimization problem, then these bounds will only be valid for any OPTIMAL solutions, it can exclude sub-optimal feasible ones.
repeated .operations_research.sat.IntegerVariableProto tightened_variables = 21;
Definition at line 2246 of file CpSolverResponse.java.
◆ setUnknownFields()
|
inline |
Definition at line 3209 of file CpSolverResponse.java.
◆ setUserTime()
|
inline |
double user_time = 16;
- Parameters
-
value The userTime to set.
- Returns
- This builder for chaining.
Definition at line 3034 of file CpSolverResponse.java.
◆ setWallTime()
|
inline |
double wall_time = 15;
- Parameters
-
value The wallTime to set.
- Returns
- This builder for chaining.
Definition at line 3003 of file CpSolverResponse.java.
The documentation for this class was generated from the following file: