36 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"SWIGRegisterExceptionCallbacks_operations_research_graph")]
50 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"SWIGRegisterExceptionArgumentCallbacks_operations_research_graph")]
56 static void SetPendingApplicationException(
string message) {
59 static void SetPendingArithmeticException(
string message) {
62 static void SetPendingDivideByZeroException(
string message) {
63 SWIGPendingException.Set(
new global::System.DivideByZeroException(message, SWIGPendingException.Retrieve()));
65 static void SetPendingIndexOutOfRangeException(
string message) {
66 SWIGPendingException.Set(
new global::System.IndexOutOfRangeException(message, SWIGPendingException.Retrieve()));
68 static void SetPendingInvalidCastException(
string message) {
69 SWIGPendingException.Set(
new global::System.InvalidCastException(message, SWIGPendingException.Retrieve()));
71 static void SetPendingInvalidOperationException(
string message) {
72 SWIGPendingException.Set(
new global::System.InvalidOperationException(message, SWIGPendingException.Retrieve()));
74 static void SetPendingIOException(
string message) {
75 SWIGPendingException.Set(
new global::System.IO.IOException(message, SWIGPendingException.Retrieve()));
77 static void SetPendingNullReferenceException(
string message) {
78 SWIGPendingException.Set(
new global::System.NullReferenceException(message, SWIGPendingException.Retrieve()));
80 static void SetPendingOutOfMemoryException(
string message) {
81 SWIGPendingException.Set(
new global::System.OutOfMemoryException(message, SWIGPendingException.Retrieve()));
83 static void SetPendingOverflowException(
string message) {
84 SWIGPendingException.Set(
new global::System.OverflowException(message, SWIGPendingException.Retrieve()));
86 static void SetPendingSystemException(
string message) {
87 SWIGPendingException.Set(
new global::System.SystemException(message, SWIGPendingException.Retrieve()));
90 static void SetPendingArgumentException(
string message,
string paramName) {
91 SWIGPendingException.Set(
new global::System.ArgumentException(message, paramName, SWIGPendingException.Retrieve()));
93 static void SetPendingArgumentNullException(
string message,
string paramName) {
94 global::System.Exception e = SWIGPendingException.Retrieve();
95 if (e !=
null) message = message +
" Inner Exception: " + e.Message;
96 SWIGPendingException.Set(
new global::System.ArgumentNullException(paramName, message));
98 static void SetPendingArgumentOutOfRangeException(
string message,
string paramName) {
99 global::System.Exception e = SWIGPendingException.Retrieve();
100 if (e !=
null) message = message +
" Inner Exception: " + e.Message;
101 SWIGPendingException.Set(
new global::System.ArgumentOutOfRangeException(paramName, message));
104 static SWIGExceptionHelper() {
108 divideByZeroDelegate,
109 indexOutOfRangeDelegate,
111 invalidOperationDelegate,
113 nullReferenceDelegate,
120 argumentNullDelegate,
121 argumentOutOfRangeDelegate);
128 [global::System.ThreadStatic]
129 private static global::System.Exception pendingException =
null;
130 private static int numExceptionsPending = 0;
131 private static global::System.Object exceptionsLock =
null;
135 bool pending =
false;
136 if (numExceptionsPending > 0)
137 if (pendingException !=
null)
143 public static void Set(global::System.Exception e) {
144 if (pendingException !=
null)
145 throw new global::System.ApplicationException(
"FATAL: An earlier pending exception from unmanaged code was missed and thus not thrown (" + pendingException.ToString() +
")", e);
146 pendingException = e;
147 lock(exceptionsLock) {
148 numExceptionsPending++;
152 public static global::System.Exception
Retrieve() {
153 global::System.Exception e =
null;
154 if (numExceptionsPending > 0) {
155 if (pendingException !=
null) {
156 e = pendingException;
157 pendingException =
null;
158 lock(exceptionsLock) {
159 numExceptionsPending--;
166 static SWIGPendingException() {
167 exceptionsLock =
new global::System.Object();
172 protected class SWIGStringHelper {
177 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"SWIGRegisterStringCallback_operations_research_graph")]
180 static string CreateString(
string cString) {
189 static protected SWIGStringHelper
swigStringHelper =
new SWIGStringHelper();
194 [global::System.Runtime.InteropServices.DllImport(
"operations_research_graph", EntryPoint=
"SWIG_csharp_string_to_c")]
195 private static extern global::System.IntPtr SWIG_csharp_string_to_c0(
int size,
int len, [global::System.Runtime.InteropServices.In,global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr, SizeParamIndex=0)]
string str);
197 [global::System.Runtime.InteropServices.DllImport(
"operations_research_graph", EntryPoint=
"SWIG_csharp_string_size")]
198 private static extern int SWIG_csharp_string_size(global::System.IntPtr str);
200 [global::System.Runtime.InteropServices.DllImport(
"operations_research_graph", EntryPoint=
"SWIG_csharp_string_str")]
201 private static extern global::System.IntPtr SWIG_csharp_string_str(global::System.IntPtr str);
205 return global::System.IntPtr.Zero;
206 global::System.Text.Encoding utf8 = global::System.Text.Encoding.UTF8;
207 return SWIG_csharp_string_to_c0(utf8.GetByteCount(str), str.Length, str);
211 int size = SWIG_csharp_string_size(str);
213 global::System.IntPtr s = SWIG_csharp_string_str(str);
214 byte[] b =
new byte[size];
215 global::System.Runtime.InteropServices.Marshal.Copy(s, b, 0, size);
216 global::System.Text.Encoding utf8 = global::System.Text.Encoding.UTF8;
217 return utf8.GetString(b);
224 static operations_research_graphPINVOKE() {
228 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_MaxFlow___")]
229 public static extern global::System.IntPtr
new_MaxFlow();
231 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_AddArcWithCapacity___")]
232 public static extern int MaxFlow_AddArcWithCapacity(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2,
int jarg3,
long jarg4);
234 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_NumNodes___")]
235 public static extern int MaxFlow_NumNodes(global::System.Runtime.InteropServices.HandleRef jarg1);
237 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_NumArcs___")]
238 public static extern int MaxFlow_NumArcs(global::System.Runtime.InteropServices.HandleRef jarg1);
240 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_Tail___")]
241 public static extern int MaxFlow_Tail(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
243 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_Head___")]
244 public static extern int MaxFlow_Head(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
246 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_Capacity___")]
247 public static extern long MaxFlow_Capacity(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
249 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_Solve___")]
250 public static extern int MaxFlow_Solve(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2,
int jarg3);
252 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_OptimalFlow___")]
253 public static extern long MaxFlow_OptimalFlow(global::System.Runtime.InteropServices.HandleRef jarg1);
255 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_Flow___")]
256 public static extern long MaxFlow_Flow(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
258 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MaxFlow_SetArcCapacity___")]
259 public static extern void MaxFlow_SetArcCapacity(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2,
long jarg3);
261 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_delete_MaxFlow___")]
262 public static extern void delete_MaxFlow(global::System.Runtime.InteropServices.HandleRef jarg1);
264 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_MinCostFlowBase___")]
267 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_delete_MinCostFlowBase___")]
270 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_MinCostFlow__SWIG_0___")]
273 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_MinCostFlow__SWIG_1___")]
276 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_MinCostFlow__SWIG_2___")]
279 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_AddArcWithCapacityAndUnitCost___")]
282 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_SetArcCapacity___")]
283 public static extern void MinCostFlow_SetArcCapacity(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2,
long jarg3);
285 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_SetNodeSupply___")]
286 public static extern void MinCostFlow_SetNodeSupply(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2,
long jarg3);
288 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Solve___")]
289 public static extern int MinCostFlow_Solve(global::System.Runtime.InteropServices.HandleRef jarg1);
291 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_SolveMaxFlowWithMinCost___")]
294 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_OptimalCost___")]
297 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_MaximumFlow___")]
300 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Flow___")]
301 public static extern long MinCostFlow_Flow(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
303 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_NumNodes___")]
304 public static extern int MinCostFlow_NumNodes(global::System.Runtime.InteropServices.HandleRef jarg1);
306 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_NumArcs___")]
307 public static extern int MinCostFlow_NumArcs(global::System.Runtime.InteropServices.HandleRef jarg1);
309 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Tail___")]
310 public static extern int MinCostFlow_Tail(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
312 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Head___")]
313 public static extern int MinCostFlow_Head(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
315 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Capacity___")]
316 public static extern long MinCostFlow_Capacity(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
318 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_Supply___")]
319 public static extern long MinCostFlow_Supply(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
321 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_UnitCost___")]
322 public static extern long MinCostFlow_UnitCost(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
324 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_delete_MinCostFlow___")]
325 public static extern void delete_MinCostFlow(global::System.Runtime.InteropServices.HandleRef jarg1);
327 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_new_LinearSumAssignment___")]
330 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_AddArcWithCost___")]
333 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_NumNodes___")]
336 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_NumArcs___")]
339 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_LeftNode___")]
342 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_RightNode___")]
345 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_Cost___")]
346 public static extern long LinearSumAssignment_Cost(global::System.Runtime.InteropServices.HandleRef jarg1,
int jarg2);
348 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_Solve___")]
351 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_OptimalCost___")]
354 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_RightMate___")]
357 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_LinearSumAssignment_AssignmentCost___")]
360 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_delete_LinearSumAssignment___")]
363 [global::System.Runtime.InteropServices.DllImport(
"google-ortools-native", EntryPoint=
"CSharp_GooglefOrToolsfGraph_MinCostFlow_SWIGUpcast___")]