/// <summary> /// Reset the cursor, so it points to the beginning of the enumerator. /// </summary> public void Reset() { _index = -1; _currentElement = null; }
/// <summary> /// Advances the enumerator to the next queue of the enumeration, if one is currently available. /// </summary> /// <returns>true, if the enumerator was succesfully advanced to the next queue; false, if the enumerator has reached the end of the enumeration.</returns> public bool MoveNext() { if ((_index < (_collection.Count - 1))) { _index = (_index + 1); _currentElement = this._collection[_index]; return true; } _index = _collection.Count; return false; }