Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
LocalSearchMonitor.java
Go to the documentation of this file.
1/* ----------------------------------------------------------------------------
2 * This file was automatically generated by SWIG (https://www.swig.org).
3 * Version 4.2.1
4 *
5 * Do not make changes to this file unless you know what you are doing - modify
6 * the SWIG interface file instead.
7 * ----------------------------------------------------------------------------- */
8
9package com.google.ortools.constraintsolver;
10
11public class LocalSearchMonitor extends SearchMonitor {
12 private transient long swigCPtr;
13
14 protected LocalSearchMonitor(long cPtr, boolean cMemoryOwn) {
15 super(mainJNI.LocalSearchMonitor_SWIGUpcast(cPtr), cMemoryOwn);
16 swigCPtr = cPtr;
17 }
18
19 protected static long getCPtr(LocalSearchMonitor obj) {
20 return (obj == null) ? 0 : obj.swigCPtr;
21 }
22
23 protected static long swigRelease(LocalSearchMonitor obj) {
24 long ptr = 0;
25 if (obj != null) {
26 if (!obj.swigCMemOwn)
27 throw new RuntimeException("Cannot release ownership as memory is not owned");
28 ptr = obj.swigCPtr;
29 obj.swigCMemOwn = false;
30 obj.delete();
31 }
32 return ptr;
33 }
34
35 @SuppressWarnings({"deprecation", "removal"})
36 protected void finalize() {
37 delete();
38 }
39
40 public synchronized void delete() {
41 if (swigCPtr != 0) {
42 if (swigCMemOwn) {
43 swigCMemOwn = false;
44 mainJNI.delete_LocalSearchMonitor(swigCPtr);
45 }
46 swigCPtr = 0;
47 }
48 super.delete();
49 }
50
51 public String toString() {
52 return mainJNI.LocalSearchMonitor_toString(swigCPtr, this);
53 }
54
58 public void beginOperatorStart() {
59 mainJNI.LocalSearchMonitor_beginOperatorStart(swigCPtr, this);
60 }
61
62 public void endOperatorStart() {
63 mainJNI.LocalSearchMonitor_endOperatorStart(swigCPtr, this);
64 }
65
67 mainJNI.LocalSearchMonitor_beginMakeNextNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op);
68 }
69
70 public void endMakeNextNeighbor(LocalSearchOperator op, boolean neighbor_found, Assignment delta, Assignment deltadelta) {
71 mainJNI.LocalSearchMonitor_endMakeNextNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op, neighbor_found, Assignment.getCPtr(delta), delta, Assignment.getCPtr(deltadelta), deltadelta);
72 }
73
75 mainJNI.LocalSearchMonitor_beginFilterNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op);
76 }
77
78 public void endFilterNeighbor(LocalSearchOperator op, boolean neighbor_found) {
79 mainJNI.LocalSearchMonitor_endFilterNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op, neighbor_found);
80 }
81
83 mainJNI.LocalSearchMonitor_beginAcceptNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op);
84 }
85
86 public void endAcceptNeighbor(LocalSearchOperator op, boolean neighbor_found) {
87 mainJNI.LocalSearchMonitor_endAcceptNeighbor(swigCPtr, this, LocalSearchOperator.getCPtr(op), op, neighbor_found);
88 }
89
90 public void beginFiltering(LocalSearchFilter filter) {
91 mainJNI.LocalSearchMonitor_beginFiltering(swigCPtr, this, LocalSearchFilter.getCPtr(filter), filter);
92 }
93
94 public void endFiltering(LocalSearchFilter filter, boolean reject) {
95 mainJNI.LocalSearchMonitor_endFiltering(swigCPtr, this, LocalSearchFilter.getCPtr(filter), filter, reject);
96 }
97
98 public boolean IsActive() {
99 return mainJNI.LocalSearchMonitor_IsActive(swigCPtr, this);
100 }
101
105 public void install() {
106 mainJNI.LocalSearchMonitor_install(swigCPtr, this);
107 }
108
109}
void endFiltering(LocalSearchFilter filter, boolean reject)
void endMakeNextNeighbor(LocalSearchOperator op, boolean neighbor_found, Assignment delta, Assignment deltadelta)
void endAcceptNeighbor(LocalSearchOperator op, boolean neighbor_found)
void endFilterNeighbor(LocalSearchOperator op, boolean neighbor_found)