com.google.ortools.constraintsolver.IntVarLocalSearchHandler Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ortools-java Show documentation
Show all versions of ortools-java Show documentation
Google OR-Tools Java project.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 4.0.2
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package com.google.ortools.constraintsolver;
public class IntVarLocalSearchHandler {
private transient long swigCPtr;
protected transient boolean swigCMemOwn;
protected IntVarLocalSearchHandler(long cPtr, boolean cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = cPtr;
}
protected static long getCPtr(IntVarLocalSearchHandler obj) {
return (obj == null) ? 0 : obj.swigCPtr;
}
@SuppressWarnings("deprecation")
protected void finalize() {
delete();
}
public synchronized void delete() {
if (swigCPtr != 0) {
if (swigCMemOwn) {
swigCMemOwn = false;
mainJNI.delete_IntVarLocalSearchHandler(swigCPtr);
}
swigCPtr = 0;
}
}
public IntVarLocalSearchHandler() {
this(mainJNI.new_IntVarLocalSearchHandler__SWIG_0(), true);
}
public IntVarLocalSearchHandler(IntVarLocalSearchHandler other) {
this(mainJNI.new_IntVarLocalSearchHandler__SWIG_1(IntVarLocalSearchHandler.getCPtr(other), other), true);
}
public IntVarLocalSearchHandler(IntVarLocalSearchOperator op) {
this(mainJNI.new_IntVarLocalSearchHandler__SWIG_2(IntVarLocalSearchOperator.getCPtr(op), op), true);
}
public void addToAssignment(IntVar var, long value, boolean active, SWIGTYPE_p_std__vectorT_int_t assignment_indices, long index, Assignment assignment) {
mainJNI.IntVarLocalSearchHandler_addToAssignment(swigCPtr, this, IntVar.getCPtr(var), var, value, active, SWIGTYPE_p_std__vectorT_int_t.getCPtr(assignment_indices), index, Assignment.getCPtr(assignment), assignment);
}
public boolean ValueFromAssignment(Assignment assignment, IntVar var, long index, int[] value) {
return mainJNI.IntVarLocalSearchHandler_ValueFromAssignment(swigCPtr, this, Assignment.getCPtr(assignment), assignment, IntVar.getCPtr(var), var, index, value);
}
public void onRevertChanges(long index, long value) {
mainJNI.IntVarLocalSearchHandler_onRevertChanges(swigCPtr, this, index, value);
}
public void onAddVars() {
mainJNI.IntVarLocalSearchHandler_onAddVars(swigCPtr, this);
}
}