Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataWebControlsDesign / System / Data / WebControls / Design / EntityDataSourceEntityTypeFilterItem.cs / 1305376 / EntityDataSourceEntityTypeFilterItem.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System.Data.Metadata.Edm; namespace System.Web.UI.Design.WebControls { internal class EntityDataSourceEntityTypeFilterItem : IComparable{ // Only one of the following should be set. This is enforced through the constructors and the fact that these fields are readonly. private readonly EntityType _entityType; // used when we have a real EntityType backing this item private readonly string _unknownEntityTypeName; // used when we have an unknown EntityTypeFilter that we still want to include in the list internal EntityDataSourceEntityTypeFilterItem(EntityType entityType) { _entityType = entityType; } internal EntityDataSourceEntityTypeFilterItem(string unknownEntityTypeName) { _unknownEntityTypeName = unknownEntityTypeName; } internal string EntityTypeName { get { if (_entityType != null) { return _entityType.Name; } else { return _unknownEntityTypeName; } } } internal EntityType EntityType { get { return _entityType; } } public override string ToString() { return EntityTypeName; } int IComparable .CompareTo(EntityDataSourceEntityTypeFilterItem other) { return (String.Compare(this.EntityTypeName, other.EntityTypeName, StringComparison.OrdinalIgnoreCase)); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System.Data.Metadata.Edm; namespace System.Web.UI.Design.WebControls { internal class EntityDataSourceEntityTypeFilterItem : IComparable{ // Only one of the following should be set. This is enforced through the constructors and the fact that these fields are readonly. private readonly EntityType _entityType; // used when we have a real EntityType backing this item private readonly string _unknownEntityTypeName; // used when we have an unknown EntityTypeFilter that we still want to include in the list internal EntityDataSourceEntityTypeFilterItem(EntityType entityType) { _entityType = entityType; } internal EntityDataSourceEntityTypeFilterItem(string unknownEntityTypeName) { _unknownEntityTypeName = unknownEntityTypeName; } internal string EntityTypeName { get { if (_entityType != null) { return _entityType.Name; } else { return _unknownEntityTypeName; } } } internal EntityType EntityType { get { return _entityType; } } public override string ToString() { return EntityTypeName; } int IComparable .CompareTo(EntityDataSourceEntityTypeFilterItem other) { return (String.Compare(this.EntityTypeName, other.EntityTypeName, StringComparison.OrdinalIgnoreCase)); } } } // 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
- DBSqlParser.cs
- TdsValueSetter.cs
- BindingListCollectionView.cs
- TableLayoutSettings.cs
- ExternalCalls.cs
- Facet.cs
- StateDesigner.TransitionInfo.cs
- Matrix3D.cs
- QfeChecker.cs
- connectionpool.cs
- MouseGestureValueSerializer.cs
- EdmConstants.cs
- ConnectionManagementSection.cs
- TypedTableGenerator.cs
- DSACryptoServiceProvider.cs
- ComponentManagerBroker.cs
- EventBuilder.cs
- Journal.cs
- LinearGradientBrush.cs
- XmlCollation.cs
- TitleStyle.cs
- MatrixKeyFrameCollection.cs
- GroupItemAutomationPeer.cs
- DataExpression.cs
- RSAPKCS1SignatureDeformatter.cs
- AttachedPropertyMethodSelector.cs
- InputMethodStateChangeEventArgs.cs
- UserPersonalizationStateInfo.cs
- ManagedWndProcTracker.cs
- RadioButton.cs
- DragCompletedEventArgs.cs
- UnescapedXmlDiagnosticData.cs
- Pair.cs
- SqlConnectionManager.cs
- ProgressBarBrushConverter.cs
- IndexedWhereQueryOperator.cs
- XsltLoader.cs
- ProjectionCamera.cs
- InkCanvas.cs
- WpfMemberInvoker.cs
- NoClickablePointException.cs
- errorpatternmatcher.cs
- SQLResource.cs
- XsltSettings.cs
- Tokenizer.cs
- BamlWriter.cs
- ProcessProtocolHandler.cs
- QilValidationVisitor.cs
- BitmapScalingModeValidation.cs
- PrivilegedConfigurationManager.cs
- URLString.cs
- RawStylusInputCustomData.cs
- CmsUtils.cs
- FileUpload.cs
- Membership.cs
- SkewTransform.cs
- IdentityValidationException.cs
- ChtmlMobileTextWriter.cs
- WindowClosedEventArgs.cs
- MatrixIndependentAnimationStorage.cs
- RoutedEventConverter.cs
- ActivityStatusChangeEventArgs.cs
- Claim.cs
- DataServiceExpressionVisitor.cs
- ValidationErrorEventArgs.cs
- RequestUriProcessor.cs
- ListenerElementsCollection.cs
- CodeCatchClause.cs
- CodeFieldReferenceExpression.cs
- ComboBoxAutomationPeer.cs
- TripleDES.cs
- DataColumnMapping.cs
- CodeDOMUtility.cs
- MimeTypeAttribute.cs
- _SslState.cs
- xml.cs
- AsymmetricAlgorithm.cs
- DeclarativeConditionsCollection.cs
- SqlMultiplexer.cs
- InstanceDataCollection.cs
- XmlTextReader.cs
- RoleManagerEventArgs.cs
- IImplicitResourceProvider.cs
- UnaryNode.cs
- DefaultAssemblyResolver.cs
- DbConnectionStringCommon.cs
- WebPartUserCapability.cs
- httpapplicationstate.cs
- input.cs
- ActivityIdHeader.cs
- SamlDoNotCacheCondition.cs
- BaseParser.cs
- ClientCredentials.cs
- CommandLibraryHelper.cs
- basecomparevalidator.cs
- ProfileGroupSettingsCollection.cs
- ProxyWebPart.cs
- AdapterDictionary.cs
- UnsafeNativeMethods.cs
- ProxyManager.cs