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
- DataGridViewAutoSizeColumnsModeEventArgs.cs
- HttpRequestCacheValidator.cs
- FastPropertyAccessor.cs
- DbParameterCollectionHelper.cs
- DataObjectCopyingEventArgs.cs
- TemplateEditingFrame.cs
- SurrogateSelector.cs
- formatter.cs
- HTTP_SERVICE_CONFIG_URLACL_PARAM.cs
- login.cs
- DispatcherSynchronizationContext.cs
- CookieHandler.cs
- Package.cs
- GcHandle.cs
- GridProviderWrapper.cs
- UntypedNullExpression.cs
- CroppedBitmap.cs
- ListViewUpdateEventArgs.cs
- MetadataItemSerializer.cs
- Panel.cs
- Matrix3D.cs
- UrlAuthFailedErrorFormatter.cs
- MultiPartWriter.cs
- ToolStripDropDown.cs
- JavascriptCallbackBehaviorAttribute.cs
- FolderBrowserDialog.cs
- Label.cs
- WorkflowRuntimeServicesBehavior.cs
- CryptoKeySecurity.cs
- ComboBox.cs
- GridView.cs
- DrawToolTipEventArgs.cs
- ListControl.cs
- ProgressPage.cs
- ObjectConverter.cs
- SettingsSavedEventArgs.cs
- NegatedCellConstant.cs
- ChtmlTextWriter.cs
- ListViewItem.cs
- Monitor.cs
- OdbcCommandBuilder.cs
- QuestionEventArgs.cs
- ResXBuildProvider.cs
- ReferencedAssembly.cs
- diagnosticsswitches.cs
- TypeTypeConverter.cs
- WorkItem.cs
- PersonalizationEntry.cs
- PrimaryKeyTypeConverter.cs
- FlowDocumentFormatter.cs
- FunctionDescription.cs
- EntityDataSourceWrapperCollection.cs
- ObjectNavigationPropertyMapping.cs
- Environment.cs
- ProfileEventArgs.cs
- TabControlCancelEvent.cs
- SignatureResourceHelper.cs
- UriParserTemplates.cs
- ProgressBarAutomationPeer.cs
- XamlTypeMapperSchemaContext.cs
- UnaryOperationBinder.cs
- CopyNodeSetAction.cs
- XmlCharCheckingWriter.cs
- ManagementEventWatcher.cs
- XamlTypeMapper.cs
- CachedFontFamily.cs
- CharAnimationBase.cs
- InternalSafeNativeMethods.cs
- TimeZone.cs
- ZoneButton.cs
- WebPartCollection.cs
- ColumnMapTranslator.cs
- TransactionChannelListener.cs
- _WebProxyDataBuilder.cs
- RsaEndpointIdentity.cs
- BitmapEditor.cs
- InternalConfigConfigurationFactory.cs
- RemoteWebConfigurationHostServer.cs
- WebPartDescription.cs
- ellipse.cs
- PartialClassGenerationTask.cs
- AttributeQuery.cs
- HostExecutionContextManager.cs
- CqlGenerator.cs
- LocationFactory.cs
- OdbcConnectionPoolProviderInfo.cs
- HtmlEmptyTagControlBuilder.cs
- RoleService.cs
- FixedSOMTableRow.cs
- ScriptingAuthenticationServiceSection.cs
- SafeViewOfFileHandle.cs
- SecurityDocument.cs
- Vector3DConverter.cs
- ThemeableAttribute.cs
- EndEvent.cs
- ToolTipAutomationPeer.cs
- SystemColorTracker.cs
- RegexWriter.cs
- RNGCryptoServiceProvider.cs
- ApplicationHost.cs