Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Xml / System / Xml / XPath / Internal / ParentQuery.cs / 1 / 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.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- UIPermission.cs
- AesManaged.cs
- DbConnectionInternal.cs
- NegotiationTokenAuthenticatorStateCache.cs
- Model3D.cs
- SwitchElementsCollection.cs
- MaskInputRejectedEventArgs.cs
- TemplateBuilder.cs
- SafeIUnknown.cs
- SynchronizationLockException.cs
- SpotLight.cs
- AnnotationStore.cs
- ActionItem.cs
- KeyValuePairs.cs
- WorkflowServiceHostFactory.cs
- SessionStateItemCollection.cs
- TextModifierScope.cs
- XmlDomTextWriter.cs
- BindingNavigatorDesigner.cs
- SizeAnimationClockResource.cs
- XmlHelper.cs
- PropertyCollection.cs
- MouseCaptureWithinProperty.cs
- HeaderCollection.cs
- CaseInsensitiveHashCodeProvider.cs
- BatchWriter.cs
- QueryExpression.cs
- ListChangedEventArgs.cs
- TokenizerHelper.cs
- Rotation3DAnimationUsingKeyFrames.cs
- WsatConfiguration.cs
- LocatorGroup.cs
- BindingCompleteEventArgs.cs
- PiiTraceSource.cs
- TransformGroup.cs
- FactoryId.cs
- InstanceStore.cs
- TraceUtility.cs
- WinHttpWebProxyFinder.cs
- FormatterConverter.cs
- DocumentScope.cs
- MemoryPressure.cs
- XPathNodeHelper.cs
- FormsAuthenticationCredentials.cs
- TrackingRecord.cs
- GetPageNumberCompletedEventArgs.cs
- ScrollChrome.cs
- ExtentCqlBlock.cs
- DataColumnChangeEvent.cs
- EntityDataSourceWizardForm.cs
- MultiTrigger.cs
- Canvas.cs
- bindurihelper.cs
- FixedSOMPage.cs
- NameService.cs
- PolyQuadraticBezierSegmentFigureLogic.cs
- MemoryRecordBuffer.cs
- DataGridViewSelectedRowCollection.cs
- ColumnPropertiesGroup.cs
- Baml6ConstructorInfo.cs
- XmlMemberMapping.cs
- SqlTrackingService.cs
- _CommandStream.cs
- BamlRecordReader.cs
- EmptyStringExpandableObjectConverter.cs
- EntitySqlQueryCacheKey.cs
- TypeToArgumentTypeConverter.cs
- AtomPub10CategoriesDocumentFormatter.cs
- HttpInputStream.cs
- WebPartAuthorizationEventArgs.cs
- String.cs
- DataServices.cs
- QueryableDataSourceView.cs
- OperationContext.cs
- ProcessHost.cs
- ICspAsymmetricAlgorithm.cs
- DataSourceDescriptorCollection.cs
- ZoomPercentageConverter.cs
- AppDomainCompilerProxy.cs
- XmlAttributeAttribute.cs
- ToolStripRendererSwitcher.cs
- DataRecordInternal.cs
- webeventbuffer.cs
- WindowsListViewGroupHelper.cs
- BaseCodeDomTreeGenerator.cs
- TextEndOfParagraph.cs
- SqlParameterizer.cs
- DefaultValueTypeConverter.cs
- EncoderParameter.cs
- Transform3D.cs
- XpsThumbnail.cs
- ValueTable.cs
- ReadOnlyHierarchicalDataSourceView.cs
- DataRowExtensions.cs
- IgnoreSection.cs
- WinEventQueueItem.cs
- Line.cs
- DocComment.cs
- IListConverters.cs
- PageHandlerFactory.cs