| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323 |
- //------------------------------------------------------------------------------
- // <auto-generated />
- //
- // This file was automatically generated by SWIG (http://www.swig.org).
- // Version 4.0.2
- //
- // Do not make changes to this file unless you know what you are doing--modify
- // the SWIG interface file instead.
- //------------------------------------------------------------------------------
- public class Point3dList : global::System.IDisposable, global::System.Collections.IEnumerable, global::System.Collections.Generic.IEnumerable<Point3d>
- {
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
- protected bool swigCMemOwn;
- internal Point3dList(global::System.IntPtr cPtr, bool cMemoryOwn) {
- swigCMemOwn = cMemoryOwn;
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Point3dList obj) {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
- ~Point3dList() {
- Dispose(false);
- }
- public void Dispose() {
- Dispose(true);
- global::System.GC.SuppressFinalize(this);
- }
- protected virtual void Dispose(bool disposing) {
- lock(this) {
- if (swigCPtr.Handle != global::System.IntPtr.Zero) {
- if (swigCMemOwn) {
- swigCMemOwn = false;
- GestureEstimatePINVOKE.delete_Point3dList(swigCPtr);
- }
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
- }
- }
- }
- public Point3dList(global::System.Collections.IEnumerable c) : this() {
- if (c == null)
- throw new global::System.ArgumentNullException("c");
- foreach (Point3d element in c) {
- this.Add(element);
- }
- }
- public Point3dList(global::System.Collections.Generic.IEnumerable<Point3d> c) : this() {
- if (c == null)
- throw new global::System.ArgumentNullException("c");
- foreach (Point3d element in c) {
- this.Add(element);
- }
- }
- public bool IsFixedSize {
- get {
- return false;
- }
- }
- public bool IsReadOnly {
- get {
- return false;
- }
- }
- public Point3d this[int index] {
- get {
- return getitem(index);
- }
- set {
- setitem(index, value);
- }
- }
- public int Capacity {
- get {
- return (int)capacity();
- }
- set {
- if (value < size())
- throw new global::System.ArgumentOutOfRangeException("Capacity");
- reserve((uint)value);
- }
- }
- public int Count {
- get {
- return (int)size();
- }
- }
- public bool IsSynchronized {
- get {
- return false;
- }
- }
- public void CopyTo(Point3d[] array)
- {
- CopyTo(0, array, 0, this.Count);
- }
- public void CopyTo(Point3d[] array, int arrayIndex)
- {
- CopyTo(0, array, arrayIndex, this.Count);
- }
- public void CopyTo(int index, Point3d[] array, int arrayIndex, int count)
- {
- if (array == null)
- throw new global::System.ArgumentNullException("array");
- if (index < 0)
- throw new global::System.ArgumentOutOfRangeException("index", "Value is less than zero");
- if (arrayIndex < 0)
- throw new global::System.ArgumentOutOfRangeException("arrayIndex", "Value is less than zero");
- if (count < 0)
- throw new global::System.ArgumentOutOfRangeException("count", "Value is less than zero");
- if (array.Rank > 1)
- throw new global::System.ArgumentException("Multi dimensional array.", "array");
- if (index+count > this.Count || arrayIndex+count > array.Length)
- throw new global::System.ArgumentException("Number of elements to copy is too large.");
- for (int i=0; i<count; i++)
- array.SetValue(getitemcopy(index+i), arrayIndex+i);
- }
- public Point3d[] ToArray() {
- Point3d[] array = new Point3d[this.Count];
- this.CopyTo(array);
- return array;
- }
- global::System.Collections.Generic.IEnumerator<Point3d> global::System.Collections.Generic.IEnumerable<Point3d>.GetEnumerator() {
- return new Point3dListEnumerator(this);
- }
- global::System.Collections.IEnumerator global::System.Collections.IEnumerable.GetEnumerator() {
- return new Point3dListEnumerator(this);
- }
- public Point3dListEnumerator GetEnumerator() {
- return new Point3dListEnumerator(this);
- }
- // Type-safe enumerator
- /// Note that the IEnumerator documentation requires an InvalidOperationException to be thrown
- /// whenever the collection is modified. This has been done for changes in the size of the
- /// collection but not when one of the elements of the collection is modified as it is a bit
- /// tricky to detect unmanaged code that modifies the collection under our feet.
- public sealed class Point3dListEnumerator : global::System.Collections.IEnumerator
- , global::System.Collections.Generic.IEnumerator<Point3d>
- {
- private Point3dList collectionRef;
- private int currentIndex;
- private object currentObject;
- private int currentSize;
- public Point3dListEnumerator(Point3dList collection) {
- collectionRef = collection;
- currentIndex = -1;
- currentObject = null;
- currentSize = collectionRef.Count;
- }
- // Type-safe iterator Current
- public Point3d Current {
- get {
- if (currentIndex == -1)
- throw new global::System.InvalidOperationException("Enumeration not started.");
- if (currentIndex > currentSize - 1)
- throw new global::System.InvalidOperationException("Enumeration finished.");
- if (currentObject == null)
- throw new global::System.InvalidOperationException("Collection modified.");
- return (Point3d)currentObject;
- }
- }
- // Type-unsafe IEnumerator.Current
- object global::System.Collections.IEnumerator.Current {
- get {
- return Current;
- }
- }
- public bool MoveNext() {
- int size = collectionRef.Count;
- bool moveOkay = (currentIndex+1 < size) && (size == currentSize);
- if (moveOkay) {
- currentIndex++;
- currentObject = collectionRef[currentIndex];
- } else {
- currentObject = null;
- }
- return moveOkay;
- }
- public void Reset() {
- currentIndex = -1;
- currentObject = null;
- if (collectionRef.Count != currentSize) {
- throw new global::System.InvalidOperationException("Collection modified.");
- }
- }
- public void Dispose() {
- currentIndex = -1;
- currentObject = null;
- }
- }
- public void Clear() {
- GestureEstimatePINVOKE.Point3dList_Clear(swigCPtr);
- }
- public void Add(Point3d x) {
- GestureEstimatePINVOKE.Point3dList_Add(swigCPtr, Point3d.getCPtr(x));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- private uint size() {
- uint ret = GestureEstimatePINVOKE.Point3dList_size(swigCPtr);
- return ret;
- }
- private uint capacity() {
- uint ret = GestureEstimatePINVOKE.Point3dList_capacity(swigCPtr);
- return ret;
- }
- private void reserve(uint n) {
- GestureEstimatePINVOKE.Point3dList_reserve(swigCPtr, n);
- }
- public Point3dList() : this(GestureEstimatePINVOKE.new_Point3dList__SWIG_0(), true) {
- }
- public Point3dList(Point3dList other) : this(GestureEstimatePINVOKE.new_Point3dList__SWIG_1(Point3dList.getCPtr(other)), true) {
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public Point3dList(int capacity) : this(GestureEstimatePINVOKE.new_Point3dList__SWIG_2(capacity), true) {
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- private Point3d getitemcopy(int index) {
- Point3d ret = new Point3d(GestureEstimatePINVOKE.Point3dList_getitemcopy(swigCPtr, index), true);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- private Point3d getitem(int index) {
- Point3d ret = new Point3d(GestureEstimatePINVOKE.Point3dList_getitem(swigCPtr, index), false);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- private void setitem(int index, Point3d val) {
- GestureEstimatePINVOKE.Point3dList_setitem(swigCPtr, index, Point3d.getCPtr(val));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public void AddRange(Point3dList values) {
- GestureEstimatePINVOKE.Point3dList_AddRange(swigCPtr, Point3dList.getCPtr(values));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public Point3dList GetRange(int index, int count) {
- global::System.IntPtr cPtr = GestureEstimatePINVOKE.Point3dList_GetRange(swigCPtr, index, count);
- Point3dList ret = (cPtr == global::System.IntPtr.Zero) ? null : new Point3dList(cPtr, true);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public void Insert(int index, Point3d x) {
- GestureEstimatePINVOKE.Point3dList_Insert(swigCPtr, index, Point3d.getCPtr(x));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public void InsertRange(int index, Point3dList values) {
- GestureEstimatePINVOKE.Point3dList_InsertRange(swigCPtr, index, Point3dList.getCPtr(values));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public void RemoveAt(int index) {
- GestureEstimatePINVOKE.Point3dList_RemoveAt(swigCPtr, index);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public void RemoveRange(int index, int count) {
- GestureEstimatePINVOKE.Point3dList_RemoveRange(swigCPtr, index, count);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public static Point3dList Repeat(Point3d value, int count) {
- global::System.IntPtr cPtr = GestureEstimatePINVOKE.Point3dList_Repeat(Point3d.getCPtr(value), count);
- Point3dList ret = (cPtr == global::System.IntPtr.Zero) ? null : new Point3dList(cPtr, true);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public void Reverse() {
- GestureEstimatePINVOKE.Point3dList_Reverse__SWIG_0(swigCPtr);
- }
- public void Reverse(int index, int count) {
- GestureEstimatePINVOKE.Point3dList_Reverse__SWIG_1(swigCPtr, index, count);
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- public void SetRange(int index, Point3dList values) {
- GestureEstimatePINVOKE.Point3dList_SetRange(swigCPtr, index, Point3dList.getCPtr(values));
- if (GestureEstimatePINVOKE.SWIGPendingException.Pending) throw GestureEstimatePINVOKE.SWIGPendingException.Retrieve();
- }
- }
|