Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Xml / System / Xml / XPath / Internal / ParentQuery.cs / 1305376 / ParentQuery.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; using System.Collections.Generic; internal sealed class ParentQuery : CacheAxisQuery { public ParentQuery(Query qyInput, string Name, string Prefix, XPathNodeType Type) : base(qyInput, Name, Prefix, Type) {} private ParentQuery(ParentQuery other) : base(other) { } public override object Evaluate(XPathNodeIterator context) { base.Evaluate(context); // XPathNavigator input; while ((input = qyInput.Advance()) != null) { input = input.Clone(); if (input.MoveToParent()) { if (matches(input)) { Insert(outputBuffer, input); } } } return this; } public override XPathNodeIterator Clone() { return new ParentQuery(this); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// 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; using System.Collections.Generic; internal sealed class ParentQuery : CacheAxisQuery { public ParentQuery(Query qyInput, string Name, string Prefix, XPathNodeType Type) : base(qyInput, Name, Prefix, Type) {} private ParentQuery(ParentQuery other) : base(other) { } public override object Evaluate(XPathNodeIterator context) { base.Evaluate(context); // XPathNavigator input; while ((input = qyInput.Advance()) != null) { input = input.Clone(); if (input.MoveToParent()) { if (matches(input)) { Insert(outputBuffer, input); } } } return this; } public override XPathNodeIterator Clone() { return new ParentQuery(this); } } } // 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
- Point3DAnimation.cs
- PeerInvitationResponse.cs
- FocusTracker.cs
- XmlTextReader.cs
- MetaModel.cs
- HttpModuleActionCollection.cs
- SymDocumentType.cs
- WebPartMinimizeVerb.cs
- AccessDataSourceView.cs
- cookiecontainer.cs
- CqlErrorHelper.cs
- SystemMulticastIPAddressInformation.cs
- InkCanvasSelection.cs
- ReflectionTypeLoadException.cs
- LinearKeyFrames.cs
- TextDataBindingHandler.cs
- RulePatternOps.cs
- UnsafeNativeMethods.cs
- EntityDataSourceContextDisposingEventArgs.cs
- SecurityIdentifierElementCollection.cs
- CFStream.cs
- NotImplementedException.cs
- MethodRental.cs
- OrderByBuilder.cs
- HtmlInputFile.cs
- OleDbDataAdapter.cs
- EdmComplexTypeAttribute.cs
- DbProviderSpecificTypePropertyAttribute.cs
- Menu.cs
- ExpressionParser.cs
- BitmapFrameDecode.cs
- ProxyGenerator.cs
- MarginCollapsingState.cs
- XmlQueryStaticData.cs
- Signature.cs
- DataServiceExpressionVisitor.cs
- _DisconnectOverlappedAsyncResult.cs
- PrintDialogException.cs
- WorkflowServiceBehavior.cs
- HttpTransportElement.cs
- CodeMemberProperty.cs
- AuthenticationManager.cs
- TemplateNodeContextMenu.cs
- ListBindableAttribute.cs
- DataSourceCache.cs
- ListMarkerSourceInfo.cs
- Config.cs
- Vector3D.cs
- CompatibleComparer.cs
- SelectionProviderWrapper.cs
- ProjectionPath.cs
- GridViewDeletedEventArgs.cs
- DynamicRendererThreadManager.cs
- SoapAttributeAttribute.cs
- IntegerValidatorAttribute.cs
- SpecularMaterial.cs
- ELinqQueryState.cs
- NameValueFileSectionHandler.cs
- X509PeerCertificateElement.cs
- PenLineJoinValidation.cs
- ZipIOFileItemStream.cs
- RubberbandSelector.cs
- IntSecurity.cs
- CodeDefaultValueExpression.cs
- DiffuseMaterial.cs
- SrgsElement.cs
- FlowPanelDesigner.cs
- SymLanguageType.cs
- PrtCap_Public.cs
- SqlXmlStorage.cs
- AccessDataSource.cs
- Switch.cs
- UdpDiscoveryMessageFilter.cs
- DataControlImageButton.cs
- ACE.cs
- SimpleTypesSurrogate.cs
- DataObjectPastingEventArgs.cs
- Span.cs
- RequestNavigateEventArgs.cs
- NameScope.cs
- InheritanceContextChangedEventManager.cs
- EntitySqlQueryState.cs
- ConfigurationValidatorAttribute.cs
- BitmapImage.cs
- InputBuffer.cs
- ImageIndexEditor.cs
- ProfileManager.cs
- Scripts.cs
- BoundsDrawingContextWalker.cs
- DesignerOptionService.cs
- Token.cs
- DurationConverter.cs
- DataFormat.cs
- HwndMouseInputProvider.cs
- WinInet.cs
- ConfigurationManagerInternal.cs
- DesignerActionPropertyItem.cs
- TextLine.cs
- WaitForChangedResult.cs
- ConfigurationSectionGroupCollection.cs