Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Xml / System / Xml / XPath / Internal / ResetableIterator.cs / 1305376 / ResetableIterator.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace MS.Internal.Xml.XPath { using System; using System.Xml; using System.Xml.XPath; using System.Diagnostics; using System.Globalization; internal abstract class ResetableIterator : XPathNodeIterator { // the best place for this constructors to be is XPathNodeIterator, to avoid DCR at this time let's ground them here public ResetableIterator() { base.count = -1; } protected ResetableIterator(ResetableIterator other) { base.count = other.count; } protected void ResetCount() { base.count = -1; } public abstract void Reset(); public virtual bool MoveToPosition(int pos) { Reset(); for(int i = CurrentPosition; i < pos ; i ++) { if(!MoveNext()) { return false; } } return true; } // Contruct extension: CurrentPosition should return 0 if MoveNext() wasn't called after Reset() // (behavior is not defined for XPathNodeIterator) public abstract override int CurrentPosition { get; } } } // 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
- BindingExpressionBase.cs
- TypeUsage.cs
- TreeNodeCollectionEditor.cs
- IsolationInterop.cs
- ECDiffieHellman.cs
- DropShadowBitmapEffect.cs
- PeerContact.cs
- ContextStaticAttribute.cs
- WindowsFormsSectionHandler.cs
- MsmqIntegrationProcessProtocolHandler.cs
- WebBrowserProgressChangedEventHandler.cs
- SHA384Managed.cs
- rsa.cs
- ServiceProviders.cs
- LinkDescriptor.cs
- EntityDataSourceViewSchema.cs
- PointConverter.cs
- HtmlForm.cs
- BitConverter.cs
- DbConnectionPoolIdentity.cs
- ObjectItemAttributeAssemblyLoader.cs
- ColumnMapTranslator.cs
- RadialGradientBrush.cs
- ProfileManager.cs
- _UncName.cs
- RegexRunnerFactory.cs
- WithParamAction.cs
- BuildProviderAppliesToAttribute.cs
- TextRangeAdaptor.cs
- ConfigurationValues.cs
- WindowsScrollBar.cs
- AddIn.cs
- Crc32.cs
- FormViewDeleteEventArgs.cs
- KeyboardNavigation.cs
- IntMinMaxAggregationOperator.cs
- IntranetCredentialPolicy.cs
- SoapFault.cs
- UnSafeCharBuffer.cs
- PrintEvent.cs
- ToolStripItemRenderEventArgs.cs
- RequestUriProcessor.cs
- InplaceBitmapMetadataWriter.cs
- TextDocumentView.cs
- LineSegment.cs
- BaseTemplateParser.cs
- ReadOnlyDataSourceView.cs
- WebProxyScriptElement.cs
- UnmanagedMemoryStreamWrapper.cs
- DataGridViewBand.cs
- PlatformCulture.cs
- HitTestParameters3D.cs
- StrokeDescriptor.cs
- GroupJoinQueryOperator.cs
- HtmlTableRow.cs
- DecoratedNameAttribute.cs
- RelOps.cs
- TemplateColumn.cs
- SafeFileMappingHandle.cs
- BindToObject.cs
- EditorOptionAttribute.cs
- hwndwrapper.cs
- ProfileProvider.cs
- OptimalTextSource.cs
- StrokeFIndices.cs
- CleanUpVirtualizedItemEventArgs.cs
- ReadOnlyDataSourceView.cs
- DataRow.cs
- PassportAuthenticationEventArgs.cs
- ToolStripItemClickedEventArgs.cs
- Color.cs
- HandleCollector.cs
- SerializableAttribute.cs
- CommandEventArgs.cs
- StartFileNameEditor.cs
- ImplicitInputBrush.cs
- Page.cs
- DetailsViewPagerRow.cs
- HyperLinkStyle.cs
- Pair.cs
- ViewPort3D.cs
- SystemTcpConnection.cs
- SpeechDetectedEventArgs.cs
- IApplicationTrustManager.cs
- FixedBufferAttribute.cs
- Int64AnimationUsingKeyFrames.cs
- MultiTouchSystemGestureLogic.cs
- RemotingConfigParser.cs
- DbProviderServices.cs
- ThreadExceptionDialog.cs
- ActionFrame.cs
- DoubleAnimation.cs
- CacheEntry.cs
- BatchServiceHost.cs
- TextEditorSpelling.cs
- XmlSchemaNotation.cs
- AmbiguousMatchException.cs
- NetworkInterface.cs
- MonikerProxyAttribute.cs
- XmlWhitespace.cs