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
- InvokeProviderWrapper.cs
- TypeDelegator.cs
- IgnorePropertiesAttribute.cs
- ColorMatrix.cs
- SelectionWordBreaker.cs
- StateInitializationDesigner.cs
- SEHException.cs
- StringFunctions.cs
- Point3DCollection.cs
- Parameter.cs
- BuildProvider.cs
- KeyedQueue.cs
- SystemNetworkInterface.cs
- LiteralText.cs
- Vertex.cs
- BaseDataListComponentEditor.cs
- DataContractSet.cs
- MethodCallTranslator.cs
- PathGeometry.cs
- ToolStripItemEventArgs.cs
- XmlSchemaFacet.cs
- httpserverutility.cs
- MarshalDirectiveException.cs
- EngineSiteSapi.cs
- CustomPopupPlacement.cs
- ComponentResourceManager.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- TextEditorLists.cs
- ViewStateException.cs
- ComAdminWrapper.cs
- _NetworkingPerfCounters.cs
- DataTableCollection.cs
- ResXResourceSet.cs
- SessionStateItemCollection.cs
- KerberosTokenFactoryCredential.cs
- DbParameterHelper.cs
- AssemblyFilter.cs
- Form.cs
- Utility.cs
- RawTextInputReport.cs
- ExpressionBuilderContext.cs
- XmlILIndex.cs
- SoapSchemaMember.cs
- LOSFormatter.cs
- DrawingContextDrawingContextWalker.cs
- ListDictionaryInternal.cs
- DocumentCollection.cs
- EventWaitHandleSecurity.cs
- SettingsPropertyWrongTypeException.cs
- JoinCqlBlock.cs
- PropertyChangingEventArgs.cs
- TypeLibConverter.cs
- SiteMapNodeCollection.cs
- Propagator.Evaluator.cs
- ObjectStateFormatter.cs
- ObjectKeyFrameCollection.cs
- SoapEnvelopeProcessingElement.cs
- TextShapeableCharacters.cs
- WebPartManager.cs
- DependentTransaction.cs
- WindowsTokenRoleProvider.cs
- DbProviderSpecificTypePropertyAttribute.cs
- Type.cs
- BasicCellRelation.cs
- DeploymentExceptionMapper.cs
- ReflectTypeDescriptionProvider.cs
- JpegBitmapDecoder.cs
- ScriptingSectionGroup.cs
- BatchWriter.cs
- TextServicesLoader.cs
- ProtocolReflector.cs
- RuleRefElement.cs
- input.cs
- UserPreference.cs
- EnumerableCollectionView.cs
- DataComponentNameHandler.cs
- TextElementEnumerator.cs
- AssemblySettingAttributes.cs
- MetafileHeader.cs
- TemplateBindingExpressionConverter.cs
- Underline.cs
- TypeToArgumentTypeConverter.cs
- RelationshipEndMember.cs
- AccessDataSource.cs
- RepeatInfo.cs
- IndexedString.cs
- RegexEditorDialog.cs
- httpserverutility.cs
- DeviceContexts.cs
- Pen.cs
- HttpListenerContext.cs
- DodSequenceMerge.cs
- HtmlMeta.cs
- MultipleViewPatternIdentifiers.cs
- XmlQueryRuntime.cs
- AutomationProperties.cs
- PanelStyle.cs
- Char.cs
- FieldBuilder.cs
- SwitchLevelAttribute.cs