15 using System.Collections;
16 using System.Collections.Generic;
19 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
22 swigCPtr =
new global::System.Runtime.InteropServices.HandleRef(
this, cPtr);
25 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(
OptimizeVar obj) {
26 return (obj ==
null) ?
new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero) : obj.swigCPtr;
35 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
40 swigCPtr =
new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero);
42 global::System.GC.SuppressFinalize(
this);
48 SwigDirectorConnect();
58 IntVar ret = (cPtr == global::System.IntPtr.Zero) ?
null :
new IntVar(cPtr,
false);
107 private void SwigDirectorConnect() {
108 if (SwigDerivedClassHasMethod(
"ToString", swigMethodTypes0))
110 if (SwigDerivedClassHasMethod(
"EnterSearch", swigMethodTypes1))
112 if (SwigDerivedClassHasMethod(
"RestartSearch", swigMethodTypes2))
114 if (SwigDerivedClassHasMethod(
"ExitSearch", swigMethodTypes3))
116 if (SwigDerivedClassHasMethod(
"BeginNextDecision", swigMethodTypes4))
118 if (SwigDerivedClassHasMethod(
"EndNextDecision", swigMethodTypes5))
120 if (SwigDerivedClassHasMethod(
"ApplyDecision", swigMethodTypes6))
122 if (SwigDerivedClassHasMethod(
"RefuteDecision", swigMethodTypes7))
124 if (SwigDerivedClassHasMethod(
"AfterDecision", swigMethodTypes8))
126 if (SwigDerivedClassHasMethod(
"BeginFail", swigMethodTypes9))
128 if (SwigDerivedClassHasMethod(
"EndFail", swigMethodTypes10))
130 if (SwigDerivedClassHasMethod(
"BeginInitialPropagation", swigMethodTypes11))
132 if (SwigDerivedClassHasMethod(
"EndInitialPropagation", swigMethodTypes12))
134 if (SwigDerivedClassHasMethod(
"AcceptSolution", swigMethodTypes13))
136 if (SwigDerivedClassHasMethod(
"AtSolution", swigMethodTypes14))
138 if (SwigDerivedClassHasMethod(
"NoMoreSolutions", swigMethodTypes15))
140 if (SwigDerivedClassHasMethod(
"LocalOptimum", swigMethodTypes16))
142 if (SwigDerivedClassHasMethod(
"AcceptDelta", swigMethodTypes17))
144 if (SwigDerivedClassHasMethod(
"AcceptNeighbor", swigMethodTypes18))
146 if (SwigDerivedClassHasMethod(
"AcceptUncheckedNeighbor", swigMethodTypes19))
148 if (SwigDerivedClassHasMethod(
"IsUncheckedSolutionLimitReached", swigMethodTypes20))
150 if (SwigDerivedClassHasMethod(
"PeriodicCheck", swigMethodTypes21))
152 if (SwigDerivedClassHasMethod(
"ProgressPercent", swigMethodTypes22))
154 if (SwigDerivedClassHasMethod(
"Accept", swigMethodTypes23))
156 if (SwigDerivedClassHasMethod(
"Install", swigMethodTypes24))
158 if (SwigDerivedClassHasMethod(
"Print", swigMethodTypes25))
160 operations_research_constraint_solverPINVOKE.
OptimizeVar_director_connect(swigCPtr, swigDelegate0, swigDelegate1, swigDelegate2, swigDelegate3, swigDelegate4, swigDelegate5, swigDelegate6, swigDelegate7, swigDelegate8, swigDelegate9, swigDelegate10, swigDelegate11, swigDelegate12, swigDelegate13, swigDelegate14, swigDelegate15, swigDelegate16, swigDelegate17, swigDelegate18, swigDelegate19, swigDelegate20, swigDelegate21, swigDelegate22, swigDelegate23, swigDelegate24, swigDelegate25);
163 private bool SwigDerivedClassHasMethod(
string methodName, global::System.Type[] methodTypes) {
164 global::System.Reflection.MethodInfo methodInfo = this.GetType().GetMethod(methodName, global::System.Reflection.BindingFlags.Public | global::System.Reflection.BindingFlags.NonPublic | global::System.Reflection.BindingFlags.Instance,
null, methodTypes,
null);
165 bool hasDerivedMethod = methodInfo.DeclaringType.IsSubclassOf(typeof(OptimizeVar));
166 return hasDerivedMethod;
169 private string SwigDirectorToString() {
173 private void SwigDirectorEnterSearch() {
177 private void SwigDirectorRestartSearch() {
181 private void SwigDirectorExitSearch() {
185 private void SwigDirectorBeginNextDecision(global::System.IntPtr db) {
186 BeginNextDecision((db == global::System.IntPtr.Zero) ?
null :
new DecisionBuilder(db,
false));
189 private void SwigDirectorEndNextDecision(global::System.IntPtr b, global::System.IntPtr d) {
190 EndNextDecision((b == global::System.IntPtr.Zero) ?
null :
new DecisionBuilder(b,
false), (d == global::System.IntPtr.Zero) ?
null :
new Decision(d,
false));
193 private void SwigDirectorApplyDecision(global::System.IntPtr d) {
194 ApplyDecision((d == global::System.IntPtr.Zero) ?
null :
new Decision(d,
false));
197 private void SwigDirectorRefuteDecision(global::System.IntPtr d) {
198 RefuteDecision((d == global::System.IntPtr.Zero) ?
null :
new Decision(d,
false));
201 private void SwigDirectorAfterDecision(global::System.IntPtr d,
bool apply) {
202 AfterDecision((d == global::System.IntPtr.Zero) ?
null :
new Decision(d,
false), apply);
205 private void SwigDirectorBeginFail() {
209 private void SwigDirectorEndFail() {
213 private void SwigDirectorBeginInitialPropagation() {
217 private void SwigDirectorEndInitialPropagation() {
221 private bool SwigDirectorAcceptSolution() {
225 private bool SwigDirectorAtSolution() {
229 private void SwigDirectorNoMoreSolutions() {
233 private bool SwigDirectorLocalOptimum() {
237 private bool SwigDirectorAcceptDelta(global::System.IntPtr delta, global::System.IntPtr deltadelta) {
238 return AcceptDelta((delta == global::System.IntPtr.Zero) ?
null :
new Assignment(delta,
false), (deltadelta == global::System.IntPtr.Zero) ?
null :
new Assignment(deltadelta,
false));
241 private void SwigDirectorAcceptNeighbor() {
245 private void SwigDirectorAcceptUncheckedNeighbor() {
249 private bool SwigDirectorIsUncheckedSolutionLimitReached() {
253 private void SwigDirectorPeriodicCheck() {
257 private int SwigDirectorProgressPercent() {
261 private void SwigDirectorAccept(global::System.IntPtr visitor) {
262 Accept((visitor == global::System.IntPtr.Zero) ?
null :
new ModelVisitor(visitor,
false));
265 private void SwigDirectorInstall() {
269 private string SwigDirectorPrint() {
327 private static global::System.Type[] swigMethodTypes0 =
new global::System.Type[] { };
328 private static global::System.Type[] swigMethodTypes1 =
new global::System.Type[] { };
329 private static global::System.Type[] swigMethodTypes2 =
new global::System.Type[] { };
330 private static global::System.Type[] swigMethodTypes3 =
new global::System.Type[] { };
331 private static global::System.Type[] swigMethodTypes4 =
new global::System.Type[] { typeof(DecisionBuilder) };
332 private static global::System.Type[] swigMethodTypes5 =
new global::System.Type[] { typeof(DecisionBuilder), typeof(Decision) };
333 private static global::System.Type[] swigMethodTypes6 =
new global::System.Type[] { typeof(Decision) };
334 private static global::System.Type[] swigMethodTypes7 =
new global::System.Type[] { typeof(Decision) };
335 private static global::System.Type[] swigMethodTypes8 =
new global::System.Type[] { typeof(Decision), typeof(
bool) };
336 private static global::System.Type[] swigMethodTypes9 =
new global::System.Type[] { };
337 private static global::System.Type[] swigMethodTypes10 =
new global::System.Type[] { };
338 private static global::System.Type[] swigMethodTypes11 =
new global::System.Type[] { };
339 private static global::System.Type[] swigMethodTypes12 =
new global::System.Type[] { };
340 private static global::System.Type[] swigMethodTypes13 =
new global::System.Type[] { };
341 private static global::System.Type[] swigMethodTypes14 =
new global::System.Type[] { };
342 private static global::System.Type[] swigMethodTypes15 =
new global::System.Type[] { };
343 private static global::System.Type[] swigMethodTypes16 =
new global::System.Type[] { };
344 private static global::System.Type[] swigMethodTypes17 =
new global::System.Type[] { typeof(Assignment), typeof(Assignment) };
345 private static global::System.Type[] swigMethodTypes18 =
new global::System.Type[] { };
346 private static global::System.Type[] swigMethodTypes19 =
new global::System.Type[] { };
347 private static global::System.Type[] swigMethodTypes20 =
new global::System.Type[] { };
348 private static global::System.Type[] swigMethodTypes21 =
new global::System.Type[] { };
349 private static global::System.Type[] swigMethodTypes22 =
new global::System.Type[] { };
350 private static global::System.Type[] swigMethodTypes23 =
new global::System.Type[] { typeof(ModelVisitor) };
351 private static global::System.Type[] swigMethodTypes24 =
new global::System.Type[] { };
352 private static global::System.Type[] swigMethodTypes25 =
new global::System.Type[] { };