Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / ndp / fx / src / DataEntity / System / Data / Map / ViewGeneration / Utils / ExternalCalls.cs / 2 / 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
- ThreadAttributes.cs
- InstanceCollisionException.cs
- ControlAdapter.cs
- Duration.cs
- ServiceNotStartedException.cs
- GridViewDesigner.cs
- Rotation3D.cs
- XPathQueryGenerator.cs
- ZoneMembershipCondition.cs
- TemplateXamlParser.cs
- RegexStringValidatorAttribute.cs
- RMPermissions.cs
- Control.cs
- SingleAnimationUsingKeyFrames.cs
- Odbc32.cs
- RuleSetDialog.Designer.cs
- KeyConstraint.cs
- DocumentViewerBase.cs
- GeneralTransform.cs
- CatalogPart.cs
- TraceLevelStore.cs
- StylusPointPropertyUnit.cs
- DataViewSettingCollection.cs
- NestedContainer.cs
- WebDisplayNameAttribute.cs
- CachingHintValidation.cs
- DecimalConstantAttribute.cs
- ValuePattern.cs
- LinkClickEvent.cs
- DataGridViewLayoutData.cs
- HandlerFactoryCache.cs
- HttpDigestClientCredential.cs
- _SpnDictionary.cs
- TextTreeUndoUnit.cs
- AsmxEndpointPickerExtension.cs
- DataGridViewRowConverter.cs
- GridViewCommandEventArgs.cs
- HashAlgorithm.cs
- PermissionToken.cs
- WebColorConverter.cs
- QueryResults.cs
- PriorityBinding.cs
- ResourceReferenceKeyNotFoundException.cs
- EndpointInfo.cs
- Run.cs
- ValidateNames.cs
- ChannelSinkStacks.cs
- XmlILAnnotation.cs
- PermissionSetEnumerator.cs
- CriticalHandle.cs
- ConfigUtil.cs
- ConnectionPointGlyph.cs
- SystemThemeKey.cs
- peernodeimplementation.cs
- LinqDataSource.cs
- _FtpDataStream.cs
- ConnectionConsumerAttribute.cs
- NegotiateStream.cs
- RawStylusInput.cs
- XmlDocumentFragment.cs
- MessageSmuggler.cs
- DataGridViewUtilities.cs
- ItemsControlAutomationPeer.cs
- CleanUpVirtualizedItemEventArgs.cs
- SchemaNames.cs
- StopStoryboard.cs
- DataTableCollection.cs
- FtpCachePolicyElement.cs
- DataKeyArray.cs
- TimerEventSubscription.cs
- CompoundFileStorageReference.cs
- EmptyControlCollection.cs
- FileDialogPermission.cs
- PointHitTestResult.cs
- WhitespaceRuleReader.cs
- HttpRuntime.cs
- SchemaType.cs
- GPRECTF.cs
- CodeArgumentReferenceExpression.cs
- TypeLibConverter.cs
- ValueOfAction.cs
- ParallelTimeline.cs
- BaseValidator.cs
- LogSwitch.cs
- Rules.cs
- ScrollChrome.cs
- ProcessModelSection.cs
- CodeDomSerializationProvider.cs
- RangeValidator.cs
- InfoCardHelper.cs
- OleDbMetaDataFactory.cs
- PtsCache.cs
- DataColumn.cs
- IxmlLineInfo.cs
- XmlSchemaInclude.cs
- NotificationContext.cs
- TableSectionStyle.cs
- Renderer.cs
- ColorMatrix.cs
- PersonalizationStateInfoCollection.cs