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 / 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
- WebZone.cs
- DebugView.cs
- ObjectStateManagerMetadata.cs
- DocumentPageView.cs
- TextMetrics.cs
- SqlClientMetaDataCollectionNames.cs
- XmlWriterTraceListener.cs
- DoubleUtil.cs
- CultureInfo.cs
- LinearGradientBrush.cs
- ProviderException.cs
- Scene3D.cs
- ParenthesizePropertyNameAttribute.cs
- CustomDictionarySources.cs
- DetailsViewDeleteEventArgs.cs
- CircleHotSpot.cs
- EncryptedData.cs
- InputQueue.cs
- odbcmetadatafactory.cs
- MetadataCache.cs
- NamedObject.cs
- FilterException.cs
- MetadataHelper.cs
- StylusOverProperty.cs
- StyleCollection.cs
- EventMetadata.cs
- Aggregates.cs
- NetMsmqBindingCollectionElement.cs
- PropertyTabAttribute.cs
- WebPartDisplayModeCollection.cs
- EntityConnectionStringBuilderItem.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- TargetException.cs
- _AutoWebProxyScriptHelper.cs
- XmlNode.cs
- FixedStringLookup.cs
- LateBoundBitmapDecoder.cs
- ObjectToIdCache.cs
- ColorConvertedBitmap.cs
- PropertyGridCommands.cs
- BulletedListEventArgs.cs
- DataGridViewBand.cs
- ObjectComplexPropertyMapping.cs
- KeyInterop.cs
- DataObjectMethodAttribute.cs
- VirtualizingPanel.cs
- UDPClient.cs
- ReferenceEqualityComparer.cs
- InArgumentConverter.cs
- AsyncOperationLifetimeManager.cs
- XmlSchemaDocumentation.cs
- DrawingServices.cs
- BreakRecordTable.cs
- wgx_render.cs
- LineProperties.cs
- MobileListItem.cs
- ScrollItemPattern.cs
- FigureParaClient.cs
- TwoPhaseCommit.cs
- isolationinterop.cs
- GeometryDrawing.cs
- EndOfStreamException.cs
- XmlSerializationGeneratedCode.cs
- MethodExpr.cs
- PageCodeDomTreeGenerator.cs
- TableHeaderCell.cs
- UshortList2.cs
- TypeExtensionSerializer.cs
- EndOfStreamException.cs
- HMACSHA384.cs
- PerformanceCounter.cs
- ArgumentOutOfRangeException.cs
- ProxySimple.cs
- StructuredCompositeActivityDesigner.cs
- ServerType.cs
- RightsManagementEncryptedStream.cs
- Int32Converter.cs
- ContentFileHelper.cs
- ServicePointManager.cs
- CngKey.cs
- ConfigXmlText.cs
- SplineQuaternionKeyFrame.cs
- XmlIgnoreAttribute.cs
- AppSettingsExpressionBuilder.cs
- Visual3D.cs
- XPathNodeIterator.cs
- BulletedListEventArgs.cs
- EDesignUtil.cs
- Helpers.cs
- FactoryGenerator.cs
- HtmlFormWrapper.cs
- SimpleHandlerFactory.cs
- DataTransferEventArgs.cs
- WebPartsPersonalization.cs
- WebBrowser.cs
- Span.cs
- PointConverter.cs
- UICuesEvent.cs
- GenericTextProperties.cs
- AuthorizationRule.cs