Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataEntity / System / Data / Map / Update / Internal / EntitySetRetriever.cs / 1 / EntitySetRetriever.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Collections.Generic; using System.Data.Common.CommandTrees; using System.Data.Metadata.Edm; namespace System.Data.Mapping.Update.Internal { ////// Retrieves extents referenced in a mapping view /// internal class EntitySetRetriever : BasicExpressionVisitor { private List_entitySets; private EntitySetRetriever() { _entitySets = new List (); } /// /// Returns all extents referenced in the given expression tree. /// /// Tree to walk. ///Extents referenced in the tree. internal static IEnumerableGetEntitySets(DbExpression tree) { EntitySetRetriever retriever = new EntitySetRetriever(); if (null != tree) { tree.Accept(retriever); } return retriever._entitySets; } /// /// Adds visited extent to the list. /// /// Scan expression. public override void Visit(DbScanExpression e) { base.Visit(e); EntitySet entitySet = e.Target as EntitySet; if (null != entitySet) { _entitySets.Add(entitySet); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Collections.Generic; using System.Data.Common.CommandTrees; using System.Data.Metadata.Edm; namespace System.Data.Mapping.Update.Internal { ////// Retrieves extents referenced in a mapping view /// internal class EntitySetRetriever : BasicExpressionVisitor { private List_entitySets; private EntitySetRetriever() { _entitySets = new List (); } /// /// Returns all extents referenced in the given expression tree. /// /// Tree to walk. ///Extents referenced in the tree. internal static IEnumerableGetEntitySets(DbExpression tree) { EntitySetRetriever retriever = new EntitySetRetriever(); if (null != tree) { tree.Accept(retriever); } return retriever._entitySets; } /// /// Adds visited extent to the list. /// /// Scan expression. public override void Visit(DbScanExpression e) { base.Visit(e); EntitySet entitySet = e.Target as EntitySet; if (null != entitySet) { _entitySets.Add(entitySet); } } } } // 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
- UrlMappingsSection.cs
- DynamicFilter.cs
- ThumbAutomationPeer.cs
- ActivityMarkupSerializationProvider.cs
- RemoteWebConfigurationHostServer.cs
- MessageHeaderAttribute.cs
- UniqueEventHelper.cs
- ChannelSettingsElement.cs
- DocumentApplicationJournalEntry.cs
- uribuilder.cs
- GlyphShapingProperties.cs
- XmlQueryType.cs
- MediaScriptCommandRoutedEventArgs.cs
- PagesSection.cs
- EditCommandColumn.cs
- ObjectFactoryCodeDomTreeGenerator.cs
- TextEffectCollection.cs
- DataBoundLiteralControl.cs
- DockPatternIdentifiers.cs
- Visual3D.cs
- SHA1.cs
- base64Transforms.cs
- HttpListener.cs
- SchemaImporterExtension.cs
- HwndTarget.cs
- Floater.cs
- Hashtable.cs
- ObjectRef.cs
- TypeConverter.cs
- Pair.cs
- XmlSchemaException.cs
- RectAnimationClockResource.cs
- CharConverter.cs
- CodeAttachEventStatement.cs
- Tablet.cs
- ByteFacetDescriptionElement.cs
- ZipPackage.cs
- DataGridViewSelectedCellsAccessibleObject.cs
- GenericPrincipal.cs
- WindowsBrush.cs
- DBParameter.cs
- IriParsingElement.cs
- DBConnection.cs
- SqlDataSourceStatusEventArgs.cs
- MetabaseSettingsIis7.cs
- Stacktrace.cs
- WindowsGraphics2.cs
- DelegateTypeInfo.cs
- OutputCacheProfile.cs
- SecurityKeyIdentifierClause.cs
- WebPartConnectionCollection.cs
- formatstringdialog.cs
- mda.cs
- WindowCollection.cs
- Polyline.cs
- xdrvalidator.cs
- SymmetricSecurityProtocolFactory.cs
- MaterialCollection.cs
- ObjectCacheHost.cs
- SmiSettersStream.cs
- WeakEventManager.cs
- CacheVirtualItemsEvent.cs
- NamespaceList.cs
- _AcceptOverlappedAsyncResult.cs
- ProfileSettingsCollection.cs
- WebResponse.cs
- DatePicker.cs
- ProfessionalColorTable.cs
- StringDictionaryCodeDomSerializer.cs
- PathParser.cs
- SafePEFileHandle.cs
- PopOutPanel.cs
- SqlInternalConnectionSmi.cs
- FontNamesConverter.cs
- SByteConverter.cs
- XPathNavigatorReader.cs
- RoutedEventHandlerInfo.cs
- PanelStyle.cs
- SqlConnectionPoolGroupProviderInfo.cs
- HealthMonitoringSection.cs
- PathGeometry.cs
- HttpHandlersSection.cs
- SystemParameters.cs
- CodeDelegateCreateExpression.cs
- ToolStripProgressBar.cs
- SelectedDatesCollection.cs
- IndexingContentUnit.cs
- FaultDescriptionCollection.cs
- ServiceDebugElement.cs
- FixedTextBuilder.cs
- QueryOutputWriter.cs
- BrushConverter.cs
- WinFormsUtils.cs
- DecimalKeyFrameCollection.cs
- SqlNodeAnnotation.cs
- SqlReferenceCollection.cs
- EdmProperty.cs
- ControlBuilderAttribute.cs
- FunctionDetailsReader.cs
- WebPartUserCapability.cs