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
- ChtmlSelectionListAdapter.cs
- StringUtil.cs
- ProfilePropertySettingsCollection.cs
- KeyValuePairs.cs
- HttpCacheVaryByContentEncodings.cs
- DataGridCaption.cs
- Privilege.cs
- FileRecordSequenceCompletedAsyncResult.cs
- HttpHandlersSection.cs
- _IPv4Address.cs
- SchemaTypeEmitter.cs
- ZipIOBlockManager.cs
- ConditionValidator.cs
- BitmapScalingModeValidation.cs
- CodeFieldReferenceExpression.cs
- EditingMode.cs
- ReflectPropertyDescriptor.cs
- CryptographicAttribute.cs
- CapabilitiesUse.cs
- CompilerResults.cs
- CodeDefaultValueExpression.cs
- GroupBox.cs
- WindowPatternIdentifiers.cs
- ColorInterpolationModeValidation.cs
- Convert.cs
- DataGridClipboardCellContent.cs
- LockCookie.cs
- XmlCodeExporter.cs
- unitconverter.cs
- CodeSnippetExpression.cs
- HtmlInputSubmit.cs
- ToolTipService.cs
- StyleCollection.cs
- PolygonHotSpot.cs
- ResourceDictionaryCollection.cs
- PropertyOrder.cs
- MachineKeySection.cs
- OrderByBuilder.cs
- XPathNavigatorReader.cs
- Filter.cs
- PropertyDescriptorCollection.cs
- SqlMethodTransformer.cs
- SchemaElementLookUpTable.cs
- CodeTypeDeclaration.cs
- MulticastIPAddressInformationCollection.cs
- FontClient.cs
- XamlWriterExtensions.cs
- AdvancedBindingPropertyDescriptor.cs
- Action.cs
- TypeReference.cs
- Unit.cs
- MappingSource.cs
- ParameterEditorUserControl.cs
- AspNetSynchronizationContext.cs
- ObjectQueryExecutionPlan.cs
- ComponentResourceKeyConverter.cs
- WhiteSpaceTrimStringConverter.cs
- TraceFilter.cs
- TextDecorations.cs
- StyleBamlRecordReader.cs
- TextDecoration.cs
- oledbmetadatacollectionnames.cs
- ContextMenuStripGroup.cs
- PcmConverter.cs
- CurrencyManager.cs
- WebServiceParameterData.cs
- AccessibleObject.cs
- ControlBindingsCollection.cs
- OutputCacheSettings.cs
- LayoutDump.cs
- UniformGrid.cs
- basevalidator.cs
- SmtpClient.cs
- VisualStateChangedEventArgs.cs
- ButtonBase.cs
- TargetInvocationException.cs
- DataObjectCopyingEventArgs.cs
- BeginEvent.cs
- ThemeDirectoryCompiler.cs
- HandleCollector.cs
- ValidationEventArgs.cs
- GacUtil.cs
- altserialization.cs
- IItemProperties.cs
- RunWorkerCompletedEventArgs.cs
- SectionUpdates.cs
- SQLDecimalStorage.cs
- Model3D.cs
- PartialCachingControl.cs
- SpellerError.cs
- QueryExecutionOption.cs
- NumberFormatInfo.cs
- MultipleViewPatternIdentifiers.cs
- DefaultParameterValueAttribute.cs
- ConfigXmlCDataSection.cs
- MenuAdapter.cs
- ObjectParameterCollection.cs
- VersionedStream.cs
- AppLevelCompilationSectionCache.cs
- DrawListViewItemEventArgs.cs