Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataWebControlsDesign / System / Data / WebControls / Design / EntityDataSourceEntityTypeFilterItem.cs / 3 / 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
- ForEachAction.cs
- FrameworkRichTextComposition.cs
- StorageTypeMapping.cs
- TypeLoadException.cs
- FullTrustAssemblyCollection.cs
- CreateUserErrorEventArgs.cs
- WebControl.cs
- TextRangeEdit.cs
- TextFormatter.cs
- EventMappingSettings.cs
- DatePickerDateValidationErrorEventArgs.cs
- InvalidTimeZoneException.cs
- DirectoryNotFoundException.cs
- DataTableCollection.cs
- _Rfc2616CacheValidators.cs
- ScriptModule.cs
- COSERVERINFO.cs
- PoisonMessageException.cs
- WebServicesDescriptionAttribute.cs
- UrlMappingCollection.cs
- SpeakCompletedEventArgs.cs
- DataGridViewCellCollection.cs
- LookupNode.cs
- rsa.cs
- Logging.cs
- KeyBinding.cs
- Utils.cs
- TextSelection.cs
- AssertSection.cs
- COM2IProvidePropertyBuilderHandler.cs
- TabletDeviceInfo.cs
- StringFunctions.cs
- NativeRightsManagementAPIsStructures.cs
- ToolStripRenderer.cs
- PublisherIdentityPermission.cs
- KeyFrames.cs
- PrintSystemException.cs
- MouseGesture.cs
- EventLogWatcher.cs
- TwoPhaseCommit.cs
- BitmapMetadata.cs
- Types.cs
- CLRBindingWorker.cs
- Profiler.cs
- EntryIndex.cs
- ContourSegment.cs
- ExpressionBindingCollection.cs
- EventToken.cs
- AudioDeviceOut.cs
- UnmanagedMemoryStream.cs
- XmlRawWriter.cs
- HostingEnvironmentSection.cs
- SqlProviderServices.cs
- ProviderBase.cs
- DefaultMemberAttribute.cs
- XamlPoint3DCollectionSerializer.cs
- IPPacketInformation.cs
- SQlBooleanStorage.cs
- DBConnectionString.cs
- TextServicesDisplayAttribute.cs
- TextReader.cs
- Vector3dCollection.cs
- NamedElement.cs
- ImplicitInputBrush.cs
- sqlcontext.cs
- ResourcesChangeInfo.cs
- SystemSounds.cs
- HyperLinkStyle.cs
- PropertyValue.cs
- Semaphore.cs
- X509ClientCertificateAuthenticationElement.cs
- ApplicationFileParser.cs
- SafeEventLogReadHandle.cs
- ColumnBinding.cs
- AppSettingsReader.cs
- HwndHostAutomationPeer.cs
- ILGenerator.cs
- MemberMemberBinding.cs
- ServiceHttpHandlerFactory.cs
- PagePropertiesChangingEventArgs.cs
- VisualProxy.cs
- InternalUserCancelledException.cs
- FreeFormDragDropManager.cs
- SystemEvents.cs
- ObjectPersistData.cs
- TableParagraph.cs
- AnimationClock.cs
- WorkflowInstanceContextProvider.cs
- ContentAlignmentEditor.cs
- ProfilePropertyMetadata.cs
- SizeAnimationUsingKeyFrames.cs
- ToolStripActionList.cs
- SessionEndedEventArgs.cs
- MeasurementDCInfo.cs
- XmlCharCheckingWriter.cs
- KeyManager.cs
- WebPartTracker.cs
- RegexWorker.cs
- InProcStateClientManager.cs
- ApplicationBuildProvider.cs