Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
AssignmentIntContainer.cs
Go to the documentation of this file.
1//------------------------------------------------------------------------------
2// <auto-generated />
3//
4// This file was automatically generated by SWIG (https://www.swig.org).
5// Version 4.2.1
6//
7// Do not make changes to this file unless you know what you are doing - modify
8// the SWIG interface file instead.
9//------------------------------------------------------------------------------
10
12
13using System;
14using System.Runtime.InteropServices;
15using System.Collections;
16using System.Collections.Generic;
17
18public partial class AssignmentIntContainer : global::System.IDisposable {
19 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
20 protected bool swigCMemOwn;
21
22 internal AssignmentIntContainer(global::System.IntPtr cPtr, bool cMemoryOwn) {
23 swigCMemOwn = cMemoryOwn;
24 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
25 }
26
27 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(AssignmentIntContainer obj) {
28 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
29 }
30
31 internal static global::System.Runtime.InteropServices.HandleRef swigRelease(AssignmentIntContainer obj) {
32 if (obj != null) {
33 if (!obj.swigCMemOwn)
34 throw new global::System.ApplicationException("Cannot release ownership as memory is not owned");
35 global::System.Runtime.InteropServices.HandleRef ptr = obj.swigCPtr;
36 obj.swigCMemOwn = false;
37 obj.Dispose();
38 return ptr;
39 } else {
40 return new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
41 }
42 }
43
44 ~AssignmentIntContainer() {
45 Dispose(false);
46 }
47
48 public void Dispose() {
49 Dispose(true);
50 global::System.GC.SuppressFinalize(this);
51 }
52
53 protected virtual void Dispose(bool disposing) {
54 lock(this) {
55 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
56 if (swigCMemOwn) {
57 swigCMemOwn = false;
59 }
60 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
61 }
62 }
63 }
64
65 public AssignmentIntContainer() : this(operations_research_constraint_solverPINVOKE.new_AssignmentIntContainer(), true) {
66 }
68 public IntVarElement Add(IntVar var) {
69 global::System.IntPtr cPtr = operations_research_constraint_solverPINVOKE.AssignmentIntContainer_Add(swigCPtr, IntVar.getCPtr(var));
70 IntVarElement ret = (cPtr == global::System.IntPtr.Zero) ? null : new IntVarElement(cPtr, false);
71 return ret;
72 }
73
74 public IntVarElement FastAdd(IntVar var) {
75 global::System.IntPtr cPtr = operations_research_constraint_solverPINVOKE.AssignmentIntContainer_FastAdd(swigCPtr, IntVar.getCPtr(var));
76 IntVarElement ret = (cPtr == global::System.IntPtr.Zero) ? null : new IntVarElement(cPtr, false);
77 return ret;
78 }
79
80 public IntVarElement AddAtPosition(IntVar var, int position) {
81 global::System.IntPtr cPtr = operations_research_constraint_solverPINVOKE.AssignmentIntContainer_AddAtPosition(swigCPtr, IntVar.getCPtr(var), position);
82 IntVarElement ret = (cPtr == global::System.IntPtr.Zero) ? null : new IntVarElement(cPtr, false);
83 return ret;
84 }
85
86 public void Clear() {
88 }
89
90 public void Resize(uint size) {
92 }
93
94 public bool Empty() {
96 return ret;
97 }
98
99 public void CopyIntersection(AssignmentIntContainer container) {
111 return ret;
112 }
113
114 public IntVarElement Element(IntVar var) {
116 return ret;
117 }
118
119 public IntVarElement Element(int index) {
121 return ret;
122 }
123
124 public int Size() {
126 return ret;
127 }
128
129 public void Store() {
132
133 public void Restore() {
136
137 public bool AreAllElementsBound() {
139 return ret;
140 }
141
142}
143
144}
IntVarElement AddAtPosition(IntVar var, int position)
static void AssignmentIntContainer_Restore(global::System.Runtime.InteropServices.HandleRef jarg1)
static global::System.IntPtr AssignmentIntContainer_Element__SWIG_0(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static void AssignmentIntContainer_Resize(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2)
static bool AssignmentIntContainer_Empty(global::System.Runtime.InteropServices.HandleRef jarg1)
static void AssignmentIntContainer_Copy(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static void delete_AssignmentIntContainer(global::System.Runtime.InteropServices.HandleRef jarg1)
static bool AssignmentIntContainer_Contains(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static global::System.IntPtr AssignmentIntContainer_Element__SWIG_1(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2)
static void AssignmentIntContainer_CopyIntersection(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static global::System.IntPtr AssignmentIntContainer_FastAdd(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static void AssignmentIntContainer_Store(global::System.Runtime.InteropServices.HandleRef jarg1)
static global::System.IntPtr AssignmentIntContainer_Add(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static global::System.IntPtr AssignmentIntContainer_AddAtPosition(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3)
static int AssignmentIntContainer_Size(global::System.Runtime.InteropServices.HandleRef jarg1)
static void AssignmentIntContainer_Clear(global::System.Runtime.InteropServices.HandleRef jarg1)
static bool AssignmentIntContainer_AreAllElementsBound(global::System.Runtime.InteropServices.HandleRef jarg1)