com.google.ortools.linearsolver.MPSolverParameters Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of google-or-tools Show documentation
Show all versions of google-or-tools Show documentation
A project to publish Google OR-Tools as a dependable dependency in Maven.
The newest version!
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.10
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package com.google.ortools.linearsolver;
import java.lang.reflect.*;
public class MPSolverParameters {
private transient long swigCPtr;
protected transient boolean swigCMemOwn;
protected MPSolverParameters(long cPtr, boolean cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = cPtr;
}
protected static long getCPtr(MPSolverParameters obj) {
return (obj == null) ? 0 : obj.swigCPtr;
}
protected void finalize() {
delete();
}
public synchronized void delete() {
if (swigCPtr != 0) {
if (swigCMemOwn) {
swigCMemOwn = false;
operations_research_linear_solverJNI.delete_MPSolverParameters(swigCPtr);
}
swigCPtr = 0;
}
}
public static double getKDefaultPrimalTolerance() {
return operations_research_linear_solverJNI.MPSolverParameters_kDefaultPrimalTolerance_get();
}
public MPSolverParameters() {
this(operations_research_linear_solverJNI.new_MPSolverParameters(), true);
}
public void setDoubleParam(MPSolverParameters.DoubleParam param, double value) {
operations_research_linear_solverJNI.MPSolverParameters_setDoubleParam(swigCPtr, this, param.swigValue(), value);
}
public double getDoubleParam(MPSolverParameters.DoubleParam param) {
return operations_research_linear_solverJNI.MPSolverParameters_getDoubleParam(swigCPtr, this, param.swigValue());
}
public enum DoubleParam {
RELATIVE_MIP_GAP(operations_research_linear_solverJNI.MPSolverParameters_RELATIVE_MIP_GAP_get());
public final int swigValue() {
return swigValue;
}
public static DoubleParam swigToEnum(int swigValue) {
DoubleParam[] swigValues = DoubleParam.class.getEnumConstants();
if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
return swigValues[swigValue];
for (DoubleParam swigEnum : swigValues)
if (swigEnum.swigValue == swigValue)
return swigEnum;
throw new IllegalArgumentException("No enum " + DoubleParam.class + " with value " + swigValue);
}
@SuppressWarnings("unused")
private DoubleParam() {
this.swigValue = SwigNext.next++;
}
@SuppressWarnings("unused")
private DoubleParam(int swigValue) {
this.swigValue = swigValue;
SwigNext.next = swigValue+1;
}
@SuppressWarnings("unused")
private DoubleParam(DoubleParam swigEnum) {
this.swigValue = swigEnum.swigValue;
SwigNext.next = this.swigValue+1;
}
private final int swigValue;
private static class SwigNext {
private static int next = 0;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy