Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataEntity / System / Data / Map / ViewGeneration / Validation / KeyConstraint.cs / 1305376 / KeyConstraint.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Data.Common.Utils; using System.Collections.Generic; using System.Text; using System.Diagnostics; namespace System.Data.Mapping.ViewGeneration.Validation { // Class representing a key constraint for particular cellrelation internal class KeyConstraint: InternalBase where TCellRelation : CellRelation { #region Constructor // Constructs a key constraint for the given relation and keyslots // with comparer being the comparison operator for comparing various // keyslots in Implies, etc internal KeyConstraint(TCellRelation relation, IEnumerable keySlots, IEqualityComparer comparer) { m_relation = relation; m_keySlots = new Set (keySlots, comparer).MakeReadOnly(); Debug.Assert(m_keySlots.Count > 0, "Key constraint being created without any keyslots?"); } #endregion #region Fields private TCellRelation m_relation; private Set m_keySlots; #endregion #region Properties protected TCellRelation CellRelation { get { return m_relation; } } protected Set KeySlots { get { return m_keySlots; } } #endregion #region Methods internal override void ToCompactString(StringBuilder builder) { StringUtil.FormatStringBuilder(builder, "Key (V{0}) - ", m_relation.CellNumber); StringUtil.ToSeparatedStringSorted(builder, KeySlots, ", "); // The slots contain the name of the relation: So we skip // printing the CellRelation } #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
- XpsException.cs
- BitmapEffectrendercontext.cs
- Journaling.cs
- ChannelManagerHelpers.cs
- CompositionTarget.cs
- SettingsProperty.cs
- VersionConverter.cs
- ChannelTokenTypeConverter.cs
- Control.cs
- SingleConverter.cs
- FrameworkPropertyMetadata.cs
- ActiveXSite.cs
- RemotingConfiguration.cs
- CancelEventArgs.cs
- TableRowCollection.cs
- PermissionSet.cs
- WindowsMenu.cs
- ZipIOCentralDirectoryBlock.cs
- XappLauncher.cs
- SqlUdtInfo.cs
- DefaultAsyncDataDispatcher.cs
- BindingsCollection.cs
- MessageBox.cs
- ServicesExceptionNotHandledEventArgs.cs
- InputBinder.cs
- OuterProxyWrapper.cs
- XmlHierarchicalEnumerable.cs
- TypeDependencyAttribute.cs
- TextFormatterHost.cs
- SecurityMode.cs
- SqlSelectStatement.cs
- LinqDataView.cs
- recordstatescratchpad.cs
- DataGridViewColumnStateChangedEventArgs.cs
- DoubleIndependentAnimationStorage.cs
- ExtensionQuery.cs
- CategoryState.cs
- WizardPanelChangingEventArgs.cs
- CustomAttributeBuilder.cs
- StreamSecurityUpgradeAcceptorAsyncResult.cs
- ToolStripItemDesigner.cs
- RuntimeComponentFilter.cs
- LabelDesigner.cs
- HashMembershipCondition.cs
- XmlSchemaDocumentation.cs
- DbParameterCollectionHelper.cs
- OleDragDropHandler.cs
- QilXmlWriter.cs
- Utils.cs
- Compiler.cs
- FrameworkElementFactory.cs
- EdmToObjectNamespaceMap.cs
- ExtenderProvidedPropertyAttribute.cs
- StringBlob.cs
- AppDomain.cs
- TextEditor.cs
- XmlSerializerSection.cs
- WsdlParser.cs
- DSASignatureFormatter.cs
- SqlExpander.cs
- GregorianCalendarHelper.cs
- ConsoleCancelEventArgs.cs
- PnrpPeerResolverElement.cs
- XComponentModel.cs
- HostSecurityManager.cs
- _ProxyRegBlob.cs
- UnsafeCollabNativeMethods.cs
- QueryCacheManager.cs
- TemplatePropertyEntry.cs
- Processor.cs
- DrawingImage.cs
- XLinq.cs
- MetaModel.cs
- MemoryPressure.cs
- LifetimeServices.cs
- ManagementObject.cs
- DmlSqlGenerator.cs
- PageThemeBuildProvider.cs
- coordinatorfactory.cs
- MenuItem.cs
- InvokeWebService.cs
- EnumValAlphaComparer.cs
- MemberJoinTreeNode.cs
- References.cs
- SqlMethodTransformer.cs
- ParseElementCollection.cs
- Identifier.cs
- UpdatePanel.cs
- XmlDocumentSerializer.cs
- DBBindings.cs
- MenuRendererClassic.cs
- ComponentGlyph.cs
- DataGridViewButtonColumn.cs
- DocumentGridContextMenu.cs
- BooleanKeyFrameCollection.cs
- Viewport2DVisual3D.cs
- TypeLibConverter.cs
- Int64AnimationBase.cs
- WebScriptMetadataMessage.cs
- XPathNavigatorKeyComparer.cs