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
- SupportingTokenBindingElement.cs
- PrintPreviewControl.cs
- DataSourceView.cs
- SelectingProviderEventArgs.cs
- DataGridViewCellValueEventArgs.cs
- TargetPerspective.cs
- TraceSection.cs
- OdbcConnectionOpen.cs
- HandoffBehavior.cs
- WSAddressing10ProblemHeaderQNameFault.cs
- ContentControl.cs
- Utils.cs
- Point.cs
- ClipboardProcessor.cs
- followingsibling.cs
- _AutoWebProxyScriptWrapper.cs
- StateMachine.cs
- WindowsBrush.cs
- ImageListUtils.cs
- XsltOutput.cs
- GridItemProviderWrapper.cs
- NegotiateStream.cs
- ServiceEndpointCollection.cs
- ListChunk.cs
- TextBoxAutomationPeer.cs
- DataGridViewCellParsingEventArgs.cs
- FamilyTypefaceCollection.cs
- TaskExceptionHolder.cs
- NetStream.cs
- BamlRecords.cs
- WCFBuildProvider.cs
- CollectionViewSource.cs
- DelegatingTypeDescriptionProvider.cs
- SecurityPermission.cs
- BufferedConnection.cs
- Model3DGroup.cs
- GeneralTransformGroup.cs
- LineBreakRecord.cs
- SeekStoryboard.cs
- PropertyInformationCollection.cs
- CharacterMetricsDictionary.cs
- ListMarkerSourceInfo.cs
- DataSourceProvider.cs
- Point4D.cs
- rsa.cs
- GestureRecognitionResult.cs
- SingleAnimationBase.cs
- DynamicResourceExtensionConverter.cs
- Pkcs7Signer.cs
- MexHttpBindingElement.cs
- DLinqAssociationProvider.cs
- Optimizer.cs
- HyperLinkDataBindingHandler.cs
- PointAnimationUsingKeyFrames.cs
- WsrmMessageInfo.cs
- SEHException.cs
- CodeDomDesignerLoader.cs
- PreviewPageInfo.cs
- WindowsGraphicsWrapper.cs
- FixedTextView.cs
- WebBrowserBase.cs
- SafeSecurityHelper.cs
- DES.cs
- XmlText.cs
- ZipIOExtraField.cs
- documentation.cs
- Empty.cs
- BaseCollection.cs
- ObjectAnimationUsingKeyFrames.cs
- RegexMatch.cs
- ParagraphResult.cs
- PageAsyncTask.cs
- SmtpNtlmAuthenticationModule.cs
- StrokeNodeOperations.cs
- TextDecoration.cs
- X509CertificateStore.cs
- ISAPIApplicationHost.cs
- Int32CollectionConverter.cs
- TcpTransportSecurityElement.cs
- OrderedDictionary.cs
- ComponentGuaranteesAttribute.cs
- AdobeCFFWrapper.cs
- StatusBarItemAutomationPeer.cs
- SQLMembershipProvider.cs
- DriveInfo.cs
- TypeSystem.cs
- DesignTimeVisibleAttribute.cs
- PointUtil.cs
- GridLength.cs
- DesignerVerbCollection.cs
- SafeLocalMemHandle.cs
- DispatcherEventArgs.cs
- SHA512.cs
- SinglePhaseEnlistment.cs
- HttpCachePolicyWrapper.cs
- InitializerFacet.cs
- RemotingSurrogateSelector.cs
- GridViewAutomationPeer.cs
- ClosableStream.cs
- StickyNoteHelper.cs