23 swigCPtr =
new global::System.Runtime.InteropServices.HandleRef(
this, cPtr);
26 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(
PathsMetadata obj) {
27 return (obj ==
null) ?
new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero) : obj.swigCPtr;
30 internal static global::System.Runtime.InteropServices.HandleRef swigRelease(PathsMetadata obj) {
33 throw new global::System.ApplicationException(
"Cannot release ownership as memory is not owned");
34 global::System.Runtime.InteropServices.HandleRef ptr = obj.swigCPtr;
35 obj.swigCMemOwn =
false;
39 return new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero);
49 global::System.GC.SuppressFinalize(
this);
52 protected virtual void Dispose(
bool disposing) {
54 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
59 swigCPtr =
new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero);
64 public PathsMetadata(RoutingIndexManager manager) : this(operations_research_constraint_solverPINVOKE.new_PathsMetadata(RoutingIndexManager.getCPtr(manager)), true) {
65 if (operations_research_constraint_solverPINVOKE.SWIGPendingException.Pending)
throw operations_research_constraint_solverPINVOKE.SWIGPendingException.Retrieve();
68 public bool IsStart(
long node) {
73 public bool IsEnd(
long node) {
78 public int GetPath(
long start_or_end_node) {
88 public long[]
Paths() {
91 if (cPtr != global::System.IntPtr.Zero) {
93 long[] outArray =
new long[tmpVector.
Count];
94 tmpVector.
CopyTo(outArray);
101 global::System.IntPtr cPtr = operations_research_constraint_solverPINVOKE.PathsMetadata_Starts(swigCPtr);
103 if (cPtr != global::System.IntPtr.Zero) {
105 long[] outArray =
new long[tmpVector.
Count];
106 tmpVector.
CopyTo(outArray);
112 public long[]
Ends() {
113 global::System.IntPtr cPtr = operations_research_constraint_solverPINVOKE.PathsMetadata_Ends(swigCPtr);
115 if (cPtr != global::System.IntPtr.Zero) {
117 long[] outArray =
new long[tmpVector.
Count];
118 tmpVector.
CopyTo(outArray);