Exemplo n.º 1
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Moves to the next entry in the enumeration
 /// </summary>
 /// <returns>True on success</returns>
 public bool MoveNext()
 {
     if (_index < (_collection.Count - 1))
     {
         _index++;
         _currentElement = _collection[_index];
         return(true);
     }
     _index = _collection.Count;
     return(false);
 }
Exemplo n.º 2
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Inserts an item into the specified position in the collection
 /// </summary>
 /// <param name="index">The zero-based index at which value should be inserted</param>
 /// <param name="value"></param>
 public void Insert(int index, T value)
 {
     this.List.Insert(index, value);
 }
Exemplo n.º 3
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Determines the index of a given item
 /// </summary>
 /// <param name="value">The item to be located</param>
 /// <returns></returns>
 public int IndexOf(T value)
 {
     return this.List.IndexOf(value);
 }
Exemplo n.º 4
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Determines whether the collection contains a specific item
 /// </summary>
 /// <param name="value">The item to be located</param>
 /// <returns>True if found</returns>
 public bool Contains(T value)
 {
     return this.List.Contains(value);
 }
Exemplo n.º 5
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Adds an item to the collection
 /// </summary>
 /// <param name="value">The item to add</param>
 /// <returns>The position into which the new element was inserted</returns>
 public int Add(T value)
 {
     return this.List.Add(value);
 }
Exemplo n.º 6
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Resets the enumeration
 /// </summary>
 public void Reset()
 {
     _index--;
     _currentElement = null;
 }
Exemplo n.º 7
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Moves to the next entry in the enumeration
 /// </summary>
 /// <returns>True on success</returns>
 public bool MoveNext()
 {
     if (_index < (_collection.Count - 1))
     {
         _index++;
         _currentElement = _collection[_index];
         return true;
     }
     _index = _collection.Count;
     return false;
 }
Exemplo n.º 8
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Removes the first occurance of the specified item in the collection
 /// </summary>
 /// <param name="value">The item to be removed</param>
 public void Remove(T value)
 {
     this.List.Remove(value);
 }
Exemplo n.º 9
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Removes the first occurance of the specified item in the collection
 /// </summary>
 /// <param name="value">The item to be removed</param>
 public void Remove(T value)
 {
     this.List.Remove(value);
 }
Exemplo n.º 10
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Determines the index of a given item
 /// </summary>
 /// <param name="value">The item to be located</param>
 /// <returns></returns>
 public int IndexOf(T value)
 {
     return(this.List.IndexOf(value));
 }
Exemplo n.º 11
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Determines whether the collection contains a specific item
 /// </summary>
 /// <param name="value">The item to be located</param>
 /// <returns>True if found</returns>
 public bool Contains(T value)
 {
     return(this.List.Contains(value));
 }
Exemplo n.º 12
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Adds an item to the collection
 /// </summary>
 /// <param name="value">The item to add</param>
 /// <returns>The position into which the new element was inserted</returns>
 public int Add(T value)
 {
     return(this.List.Add(value));
 }
Exemplo n.º 13
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Resets the enumeration
 /// </summary>
 public void Reset()
 {
     _index--;
     _currentElement = null;
 }
Exemplo n.º 14
0
 //-------------------------------------------------------------------------------------------
 /// <summary>
 /// Inserts an item into the specified position in the collection
 /// </summary>
 /// <param name="index">The zero-based index at which value should be inserted</param>
 /// <param name="value"></param>
 public void Insert(int index, T value)
 {
     this.List.Insert(index, value);
 }