Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / Util / DoubleLinkListEnumerator.cs / 1 / DoubleLinkListEnumerator.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * DoubleLinkList * * Copyright (c) 1998-1999, Microsoft Corporation * */ namespace System.Web.Util { using System.Runtime.Serialization.Formatters; using System.Collections; internal class DoubleLinkListEnumerator : IEnumerator { private DoubleLinkList _list; private DoubleLink _current; internal DoubleLinkListEnumerator(DoubleLinkList list) { _list = list; _current = list; } public void Reset() { _current = _list; } public bool MoveNext() { if (_current.Next == _list) { _current = null; return false; } _current = _current.Next; return true; } public Object Current { get { if (_current == null || _current == _list) throw new InvalidOperationException(); return _current.Item; } } internal DoubleLink GetDoubleLink() { return _current; } #if UNUSED_CODE internal void Remove() { if (_current == null || _current == _list) throw new InvalidOperationException(); DoubleLink t = _current; _current = _current.Prev; t.Remove(); } #endif } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * DoubleLinkList * * Copyright (c) 1998-1999, Microsoft Corporation * */ namespace System.Web.Util { using System.Runtime.Serialization.Formatters; using System.Collections; internal class DoubleLinkListEnumerator : IEnumerator { private DoubleLinkList _list; private DoubleLink _current; internal DoubleLinkListEnumerator(DoubleLinkList list) { _list = list; _current = list; } public void Reset() { _current = _list; } public bool MoveNext() { if (_current.Next == _list) { _current = null; return false; } _current = _current.Next; return true; } public Object Current { get { if (_current == null || _current == _list) throw new InvalidOperationException(); return _current.Item; } } internal DoubleLink GetDoubleLink() { return _current; } #if UNUSED_CODE internal void Remove() { if (_current == null || _current == _list) throw new InvalidOperationException(); DoubleLink t = _current; _current = _current.Prev; t.Remove(); } #endif } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TypeUtil.cs
- ButtonRenderer.cs
- DesignConnection.cs
- DataServiceHostFactory.cs
- HitTestParameters.cs
- CriticalFinalizerObject.cs
- VideoDrawing.cs
- HeaderFilter.cs
- ProfileGroupSettings.cs
- ContentValidator.cs
- ConfigurationPropertyCollection.cs
- DesignTimeParseData.cs
- ResourcesGenerator.cs
- DirectoryInfo.cs
- TransformDescriptor.cs
- ServiceKnownTypeAttribute.cs
- ObjRef.cs
- MetadataPropertyAttribute.cs
- TextBox.cs
- TextElementEnumerator.cs
- CompilationSection.cs
- SharedDp.cs
- TrueReadOnlyCollection.cs
- ExpressionBinding.cs
- TextHidden.cs
- RuntimeResourceSet.cs
- XmlMembersMapping.cs
- SkipQueryOptionExpression.cs
- TextElementCollection.cs
- _AcceptOverlappedAsyncResult.cs
- ListenerConstants.cs
- PartialTrustHelpers.cs
- DataServiceStreamProviderWrapper.cs
- SplineKeyFrames.cs
- TypeToArgumentTypeConverter.cs
- TextDecorationCollection.cs
- BuildManagerHost.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- StrongNameUtility.cs
- MediaEntryAttribute.cs
- Profiler.cs
- DesignerLoader.cs
- Array.cs
- UIElement.cs
- MDIWindowDialog.cs
- ClientData.cs
- SpecialNameAttribute.cs
- EventsTab.cs
- PointHitTestResult.cs
- Visual3D.cs
- IPGlobalProperties.cs
- ThicknessAnimationBase.cs
- PartitionerQueryOperator.cs
- OutKeywords.cs
- DivideByZeroException.cs
- Misc.cs
- Logging.cs
- TCPListener.cs
- ExpressionHelper.cs
- CacheEntry.cs
- ExpressionVisitor.cs
- DocumentPaginator.cs
- PointKeyFrameCollection.cs
- WsatEtwTraceListener.cs
- AlphaSortedEnumConverter.cs
- ContentFilePart.cs
- AlternateView.cs
- ViewGenResults.cs
- Quaternion.cs
- wmiprovider.cs
- TraceInternal.cs
- InvokePattern.cs
- DesignerValidationSummaryAdapter.cs
- Control.cs
- Size.cs
- XamlStyleSerializer.cs
- Pen.cs
- Model3DGroup.cs
- keycontainerpermission.cs
- HttpWebResponse.cs
- Propagator.JoinPropagator.cs
- ScaleTransform3D.cs
- VisualStyleElement.cs
- InitializingNewItemEventArgs.cs
- TypeConverterHelper.cs
- UrlRoutingHandler.cs
- DBPropSet.cs
- _TransmitFileOverlappedAsyncResult.cs
- DataGridViewRowHeightInfoPushedEventArgs.cs
- Schema.cs
- SectionRecord.cs
- ProjectionCamera.cs
- TableLayoutRowStyleCollection.cs
- Calendar.cs
- ConnectionInterfaceCollection.cs
- CollectionExtensions.cs
- RealizationDrawingContextWalker.cs
- Types.cs
- Int16.cs
- WindowsFormsHost.cs