14using System.Runtime.InteropServices;
18public class KeywordVector : global::System.IDisposable, global::System.Collections.IEnumerable, global::System.Collections.Generic.IEnumerable<SWIGTYPE_p_KeywordPair>
20 private Object locker =
new Object();
21 private HandleRef swigCPtr;
23 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
26 swigCPtr =
new HandleRef(
this, cPtr);
28 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
30 return (obj ==
null) ?
new HandleRef(
null, IntPtr.Zero) : obj.swigCPtr;
39 global::System.GC.SuppressFinalize(
this);
42 protected virtual void Dispose(
bool disposing) {
44 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
49 swigCPtr =
new global::System.Runtime.InteropServices.HandleRef(
null, global::System.IntPtr.Zero);
54 public KeywordVector(global::System.Collections.IEnumerable c) : this() {
56 throw new global::System.ArgumentNullException(
"c");
64 throw new global::System.ArgumentNullException(
"c");
84 return getitem(index);
87 setitem(index,
value);
93 return (
int)capacity();
97 throw new global::System.ArgumentOutOfRangeException(
"Capacity");
127 throw new global::System.ArgumentNullException(
"array");
129 throw new global::System.ArgumentOutOfRangeException(
"index",
"Value is less than zero");
131 throw new global::System.ArgumentOutOfRangeException(
"arrayIndex",
"Value is less than zero");
133 throw new global::System.ArgumentOutOfRangeException(
"count",
"Value is less than zero");
135 throw new global::System.ArgumentException(
"Multi dimensional array.",
"array");
136 if (index+count > this.
Count || arrayIndex+count > array.Length)
137 throw new global::System.ArgumentException(
"Number of elements to copy is too large.");
138 for (
int i=0; i<count; i++)
139 array.SetValue(getitemcopy(index+i), arrayIndex+i);
149 return new KeywordVectorEnumerator(
this);
152 global::System.Collections.IEnumerator global::System.Collections.IEnumerable.GetEnumerator() {
153 return new KeywordVectorEnumerator(
this);
166 , global::System.Collections.Generic.IEnumerator<SWIGTYPE_p_KeywordPair>
169 private int currentIndex;
170 private object currentObject;
171 private int currentSize;
174 collectionRef = collection;
176 currentObject =
null;
177 currentSize = collectionRef.
Count;
183 if (currentIndex == -1)
184 throw new global::System.InvalidOperationException(
"Enumeration not started.");
185 if (currentIndex > currentSize - 1)
186 throw new global::System.InvalidOperationException(
"Enumeration finished.");
187 if (currentObject ==
null)
188 throw new global::System.InvalidOperationException(
"Collection modified.");
194 object global::System.Collections.IEnumerator.Current {
201 int size = collectionRef.
Count;
202 bool moveOkay = (currentIndex+1 < size) && (size == currentSize);
205 currentObject = collectionRef[currentIndex];
207 currentObject =
null;
214 currentObject =
null;
215 if (collectionRef.
Count != currentSize) {
216 throw new global::System.InvalidOperationException(
"Collection modified.");
222 currentObject =
null;
236 private uint size() {
242 private uint capacity() {
243 uint ret = PCADGlobalsPINVOKE.KeywordVector_capacity(swigCPtr);
244 if (PCADGlobalsPINVOKE.SWIGPendingException.Pending)
throw PCADGlobalsPINVOKE.SWIGPendingException.Retrieve();
248 private void reserve(uint n) {
249 PCADGlobalsPINVOKE.KeywordVector_reserve(swigCPtr, n);
250 if (PCADGlobalsPINVOKE.SWIGPendingException.Pending)
throw PCADGlobalsPINVOKE.SWIGPendingException.Retrieve();
271 private SWIGTYPE_p_KeywordPair getitem(
int index) {
272 SWIGTYPE_p_KeywordPair ret =
new SWIGTYPE_p_KeywordPair(PCADGlobalsPINVOKE.KeywordVector_getitem(swigCPtr, index),
false);
273 if (PCADGlobalsPINVOKE.SWIGPendingException.Pending)
throw PCADGlobalsPINVOKE.SWIGPendingException.Retrieve();
277 private void setitem(
int index, SWIGTYPE_p_KeywordPair val) {
278 PCADGlobalsPINVOKE.KeywordVector_setitem(swigCPtr, index, SWIGTYPE_p_KeywordPair.getCPtr(val));
279 if (PCADGlobalsPINVOKE.SWIGPendingException.Pending)
throw PCADGlobalsPINVOKE.SWIGPendingException.Retrieve();
SWIGTYPE_p_KeywordPair Current
KeywordVectorEnumerator(KeywordVector collection)
KeywordVector(global::System.Collections.IEnumerable c)
KeywordVector(IntPtr cPtr, bool cMemoryOwn)
void Insert(int index, SWIGTYPE_p_KeywordPair x)
virtual void Dispose(bool disposing)
void SetRange(int index, KeywordVector values)
void CopyTo(SWIGTYPE_p_KeywordPair[] array)
KeywordVector(int capacity)
static HandleRef getCPtr(KeywordVector obj)
void AddRange(KeywordVector values)
KeywordVectorEnumerator GetEnumerator()
void RemoveRange(int index, int count)
void CopyTo(int index, SWIGTYPE_p_KeywordPair[] array, int arrayIndex, int count)
KeywordVector GetRange(int index, int count)
SWIGTYPE_p_KeywordPair[] ToArray()
void CopyTo(SWIGTYPE_p_KeywordPair[] array, int arrayIndex)
void Add(SWIGTYPE_p_KeywordPair x)
KeywordVector(KeywordVector other)
KeywordVector(global::System.Collections.Generic.IEnumerable< SWIGTYPE_p_KeywordPair > c)
void Reverse(int index, int count)
static KeywordVector Repeat(SWIGTYPE_p_KeywordPair value, int count)
void InsertRange(int index, KeywordVector values)
static global::System.Exception Retrieve()
static global::System.IntPtr KeywordVector_GetRange(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, int jarg3)
static global::System.IntPtr KeywordVector_getitemcopy(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2)
static void KeywordVector_RemoveAt(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2)
static void KeywordVector_Insert(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, global::System.Runtime.InteropServices.HandleRef jarg3)
static void KeywordVector_AddRange(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static void KeywordVector_Clear(global::System.Runtime.InteropServices.HandleRef jarg1)
static void KeywordVector_InsertRange(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, global::System.Runtime.InteropServices.HandleRef jarg3)
static uint KeywordVector_size(global::System.Runtime.InteropServices.HandleRef jarg1)
static void KeywordVector_Add(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static global::System.IntPtr KeywordVector_Repeat(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2)
static void KeywordVector_Reverse__SWIG_1(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, int jarg3)
static void KeywordVector_SetRange(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, global::System.Runtime.InteropServices.HandleRef jarg3)
static void KeywordVector_Reverse__SWIG_0(global::System.Runtime.InteropServices.HandleRef jarg1)
static void delete_KeywordVector(global::System.Runtime.InteropServices.HandleRef jarg1)
static void KeywordVector_RemoveRange(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, int jarg3)