Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / ndp / fx / src / DataEntity / System / Data / Map / ViewGeneration / Utils / ExternalCalls.cs / 1 / ExternalCalls.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Data.Mapping.ViewGeneration.Structures; using System.Data.Common.CommandTrees; using System.Data.Common.EntitySql; using System.Data.Metadata.Edm; using System.Diagnostics; using System.Collections.Generic; namespace System.Data.Mapping.ViewGeneration.Utils { // This class encapsulates "external" calls from view generation // to other System.Data.Entity components internal static class ExternalCalls { static internal bool IsReservedKeyword(string name) { return CqlLexer.IsReservedKeyword(name); } static internal DbCommandTree CompileView(string viewDef, MetadataWorkspace metadataWorkspace, ParserOptions.CompilationMode compilationMode) { Perspective perspective = new TargetPerspective(metadataWorkspace); ParserOptions parserOptions = new ParserOptions(); parserOptions.ParserCompilationMode = compilationMode; DbCommandTree expr = CqlQuery.Compile(viewDef, perspective, parserOptions, null, null, true); Debug.Assert(expr != null, "Compile returned empty tree?"); return expr; } static internal ItemCollection GetItemCollection(MetadataWorkspace workspace, DataSpace space) { return workspace.GetItemCollection(space); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Data.Mapping.ViewGeneration.Structures; using System.Data.Common.CommandTrees; using System.Data.Common.EntitySql; using System.Data.Metadata.Edm; using System.Diagnostics; using System.Collections.Generic; namespace System.Data.Mapping.ViewGeneration.Utils { // This class encapsulates "external" calls from view generation // to other System.Data.Entity components internal static class ExternalCalls { static internal bool IsReservedKeyword(string name) { return CqlLexer.IsReservedKeyword(name); } static internal DbCommandTree CompileView(string viewDef, MetadataWorkspace metadataWorkspace, ParserOptions.CompilationMode compilationMode) { Perspective perspective = new TargetPerspective(metadataWorkspace); ParserOptions parserOptions = new ParserOptions(); parserOptions.ParserCompilationMode = compilationMode; DbCommandTree expr = CqlQuery.Compile(viewDef, perspective, parserOptions, null, null, true); Debug.Assert(expr != null, "Compile returned empty tree?"); return expr; } static internal ItemCollection GetItemCollection(MetadataWorkspace workspace, DataSpace space) { return workspace.GetItemCollection(space); } } } // 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
- FlowLayout.cs
- DataServiceProcessingPipelineEventArgs.cs
- RuleRef.cs
- configsystem.cs
- DataReaderContainer.cs
- StylusOverProperty.cs
- MenuItemBindingCollection.cs
- MimePart.cs
- WhitespaceSignificantCollectionAttribute.cs
- AssemblyInfo.cs
- ErrorWrapper.cs
- DllNotFoundException.cs
- RemotingClientProxy.cs
- HtmlUtf8RawTextWriter.cs
- ObjectViewFactory.cs
- PropertyIDSet.cs
- PerspectiveCamera.cs
- FamilyCollection.cs
- ConfigXmlText.cs
- ViewCellRelation.cs
- HWStack.cs
- MessagingActivityHelper.cs
- IdentityNotMappedException.cs
- PrinterResolution.cs
- DbExpressionRules.cs
- StoragePropertyMapping.cs
- SqlTrackingQuery.cs
- MailDefinition.cs
- Peer.cs
- WindowsSolidBrush.cs
- DesignerAttribute.cs
- EntityDataSourceConfigureObjectContext.cs
- SystemResourceKey.cs
- HtmlEncodedRawTextWriter.cs
- StrongNameMembershipCondition.cs
- UseAttributeSetsAction.cs
- ColumnResizeAdorner.cs
- Container.cs
- TemplateControlCodeDomTreeGenerator.cs
- DynamicResourceExtensionConverter.cs
- MetadataItemSerializer.cs
- NumberFunctions.cs
- ACE.cs
- TypeSystem.cs
- Mutex.cs
- Intellisense.cs
- PropertyEntry.cs
- SystemWebExtensionsSectionGroup.cs
- PenCursorManager.cs
- WorkflowWebService.cs
- PropertyItem.cs
- EUCJPEncoding.cs
- RefreshEventArgs.cs
- TextRangeBase.cs
- PersonalizationAdministration.cs
- KnownAssemblyEntry.cs
- ScriptControlManager.cs
- CapabilitiesAssignment.cs
- FixedSOMLineRanges.cs
- DataBindingExpressionBuilder.cs
- CodeLinePragma.cs
- counter.cs
- HtmlControl.cs
- AppSettingsExpressionBuilder.cs
- GridSplitter.cs
- SQLByteStorage.cs
- DBSchemaRow.cs
- QueryCacheManager.cs
- MembershipUser.cs
- LZCodec.cs
- MasterPageCodeDomTreeGenerator.cs
- SqlParameterCollection.cs
- Timeline.cs
- HatchBrush.cs
- GridViewSortEventArgs.cs
- ApplicationException.cs
- LinqDataSourceInsertEventArgs.cs
- MaskedTextBox.cs
- DisplayNameAttribute.cs
- BuildProviderCollection.cs
- ExtensionQuery.cs
- CaseStatement.cs
- WindowsFormsHelpers.cs
- DesignOnlyAttribute.cs
- PinnedBufferMemoryStream.cs
- FileDialogPermission.cs
- PersistenceTask.cs
- BaseInfoTable.cs
- ProtocolsConfigurationEntry.cs
- PrintPreviewControl.cs
- FontSourceCollection.cs
- AssemblyBuilder.cs
- MeshGeometry3D.cs
- WebScriptServiceHostFactory.cs
- XmlSchemaAll.cs
- MouseActionConverter.cs
- CacheEntry.cs
- FieldNameLookup.cs
- PrimitiveSchema.cs
- MobileControlsSectionHandler.cs