Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataEntity / System / Data / Map / ViewGeneration / CqlGeneration / UnionCqlBlock.cs / 1 / UnionCqlBlock.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Collections.Generic; using System.Text; using System.Data.Mapping.ViewGeneration.Structures; using System.Data.Common.Utils; namespace System.Data.Mapping.ViewGeneration.CqlGeneration { // This class corresponds to Union nodes in the tree internal class UnionCqlBlock : CqlBlock { #region Constructor // effects: Creates a union CqlBlock with SELECT (slotinfos), FROM // (children), WHERE (true), AS (blockAliasNum) internal UnionCqlBlock(SlotInfo[] slotInfos, Listchildren, CqlIdentifiers identifiers, int blockAliasNum) : base(slotInfos, children, BoolExpression.True, identifiers, blockAliasNum) { } #endregion #region Methods // effects: See CqlBlock.AsCql internal override StringBuilder AsCql(StringBuilder builder, bool isTopLevel, int indentLevel) { // Simply get the Cql versions of the children and add the union // operator between them bool isFirst = true; foreach (CqlBlock child in Children) { if (false == isFirst) { StringUtil.IndentNewLine(builder, indentLevel + 1); builder.Append(OpCellTreeNode.OpToCql(CellTreeOpType.Union)); } isFirst = false; builder.Append(" ("); child.AsCql(builder, isTopLevel, indentLevel + 1); builder.Append(')'); } return builder; } #endregion } } // 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.Text; using System.Data.Mapping.ViewGeneration.Structures; using System.Data.Common.Utils; namespace System.Data.Mapping.ViewGeneration.CqlGeneration { // This class corresponds to Union nodes in the tree internal class UnionCqlBlock : CqlBlock { #region Constructor // effects: Creates a union CqlBlock with SELECT (slotinfos), FROM // (children), WHERE (true), AS (blockAliasNum) internal UnionCqlBlock(SlotInfo[] slotInfos, Listchildren, CqlIdentifiers identifiers, int blockAliasNum) : base(slotInfos, children, BoolExpression.True, identifiers, blockAliasNum) { } #endregion #region Methods // effects: See CqlBlock.AsCql internal override StringBuilder AsCql(StringBuilder builder, bool isTopLevel, int indentLevel) { // Simply get the Cql versions of the children and add the union // operator between them bool isFirst = true; foreach (CqlBlock child in Children) { if (false == isFirst) { StringUtil.IndentNewLine(builder, indentLevel + 1); builder.Append(OpCellTreeNode.OpToCql(CellTreeOpType.Union)); } isFirst = false; builder.Append(" ("); child.AsCql(builder, isTopLevel, indentLevel + 1); builder.Append(')'); } return builder; } #endregion } } // 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
- WS2007FederationHttpBinding.cs
- IntSecurity.cs
- odbcmetadatafactory.cs
- DesignTimeParseData.cs
- TargetPerspective.cs
- Token.cs
- XmlTextEncoder.cs
- ProxyWebPartConnectionCollection.cs
- XmlUtil.cs
- SoapExtensionTypeElementCollection.cs
- CollectionsUtil.cs
- OdbcConnectionFactory.cs
- ProfileBuildProvider.cs
- Int16AnimationBase.cs
- FolderLevelBuildProviderCollection.cs
- StaticSiteMapProvider.cs
- MatrixKeyFrameCollection.cs
- IgnoreFileBuildProvider.cs
- HtmlTableRowCollection.cs
- BlurEffect.cs
- TextServicesPropertyRanges.cs
- BaseHashHelper.cs
- coordinator.cs
- EntityCommandExecutionException.cs
- CustomExpressionEventArgs.cs
- EntityDataSourceContextDisposingEventArgs.cs
- BitmapSource.cs
- HtmlContainerControl.cs
- ReferencedAssembly.cs
- GeneralTransform.cs
- SelectionPattern.cs
- AesManaged.cs
- SqlDataSourceDesigner.cs
- FilteredXmlReader.cs
- PageStatePersister.cs
- MD5Cng.cs
- StorageModelBuildProvider.cs
- MenuItem.cs
- ToolStripDropTargetManager.cs
- CompilerResults.cs
- PassportAuthenticationModule.cs
- MarkerProperties.cs
- SkinBuilder.cs
- DropSource.cs
- DataObject.cs
- HashCodeCombiner.cs
- BindingGroup.cs
- IntAverageAggregationOperator.cs
- ClockController.cs
- Int32CAMarshaler.cs
- DefaultPropertyAttribute.cs
- StylusButton.cs
- CheckBox.cs
- WebPartsPersonalizationAuthorization.cs
- activationcontext.cs
- StreamWriter.cs
- GridEntry.cs
- UnionExpr.cs
- FormatControl.cs
- PropertyBuilder.cs
- LocatorPart.cs
- DataGridItemAttachedStorage.cs
- CustomBindingCollectionElement.cs
- XmlSchemaComplexContent.cs
- FrameAutomationPeer.cs
- WindowsSlider.cs
- OleCmdHelper.cs
- COSERVERINFO.cs
- RotateTransform.cs
- ProviderIncompatibleException.cs
- WorkflowTimerService.cs
- RequestCachePolicy.cs
- SchemaNamespaceManager.cs
- PropertyOrder.cs
- ToolStripLocationCancelEventArgs.cs
- ExpressionParser.cs
- RuntimeIdentifierPropertyAttribute.cs
- MultiBinding.cs
- CommittableTransaction.cs
- XmlSortKeyAccumulator.cs
- JsonDeserializer.cs
- EndpointDiscoveryMetadataCD1.cs
- ContextBase.cs
- TextServicesLoader.cs
- SourceElementsCollection.cs
- ObjectPropertyMapping.cs
- RequestCacheManager.cs
- PropertyEmitterBase.cs
- CriticalHandle.cs
- ManagementBaseObject.cs
- ZipIOCentralDirectoryBlock.cs
- SystemIPGlobalProperties.cs
- MultiSelectRootGridEntry.cs
- FormViewUpdatedEventArgs.cs
- MsmqAppDomainProtocolHandler.cs
- RangeContentEnumerator.cs
- Span.cs
- SystemIPAddressInformation.cs
- SetState.cs
- SqlBinder.cs