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
- StringToken.cs
- SmiEventSink_DeferedProcessing.cs
- DataGridViewColumnEventArgs.cs
- SoapCodeExporter.cs
- AbsoluteQuery.cs
- LinqTreeNodeEvaluator.cs
- TextRange.cs
- TokenBasedSetEnumerator.cs
- SchemaDeclBase.cs
- ThemeableAttribute.cs
- WebPartConnectionCollection.cs
- SmtpSpecifiedPickupDirectoryElement.cs
- HealthMonitoringSection.cs
- XPathNodeInfoAtom.cs
- PlatformNotSupportedException.cs
- UriTemplateVariablePathSegment.cs
- EnumMemberAttribute.cs
- StickyNoteHelper.cs
- ClientConvert.cs
- SimplePropertyEntry.cs
- ResourceAssociationSet.cs
- DbDataRecord.cs
- StaticFileHandler.cs
- XmlElementAttributes.cs
- RightsManagementInformation.cs
- StorageConditionPropertyMapping.cs
- FunctionUpdateCommand.cs
- EdmType.cs
- ControlUtil.cs
- TextTreeInsertElementUndoUnit.cs
- CursorConverter.cs
- XmlWriterDelegator.cs
- MeshGeometry3D.cs
- BamlResourceDeserializer.cs
- ToolStripItemEventArgs.cs
- Rectangle.cs
- DataGridViewCellParsingEventArgs.cs
- HijriCalendar.cs
- DataColumnMappingCollection.cs
- Span.cs
- RuntimeIdentifierPropertyAttribute.cs
- ReflectionHelper.cs
- SerializationException.cs
- OperationAbortedException.cs
- SystemFonts.cs
- Group.cs
- ContractHandle.cs
- StorageEntityContainerMapping.cs
- StatusStrip.cs
- XmlSignatureManifest.cs
- Int64Animation.cs
- ThrowHelper.cs
- PlacementWorkspace.cs
- InternalTransaction.cs
- AQNBuilder.cs
- CLRBindingWorker.cs
- XmlAtomicValue.cs
- QueuePathDialog.cs
- GridViewItemAutomationPeer.cs
- Compress.cs
- ErrorLog.cs
- ConfigurationSchemaErrors.cs
- ConfigurationManagerHelper.cs
- HostVisual.cs
- ColorAnimation.cs
- GZipDecoder.cs
- XNodeNavigator.cs
- LineBreak.cs
- OleDbConnectionInternal.cs
- OrderedDictionaryStateHelper.cs
- SQLConvert.cs
- Substitution.cs
- SimpleType.cs
- SecurityTokenResolver.cs
- ObjectQuery.cs
- ObjectDataSource.cs
- OpenCollectionAsyncResult.cs
- BuildProviderCollection.cs
- LayoutDump.cs
- EntityDescriptor.cs
- GeneratedContractType.cs
- FamilyMap.cs
- ProtocolsConfigurationEntry.cs
- ellipse.cs
- AspCompat.cs
- QilInvoke.cs
- ScriptingJsonSerializationSection.cs
- WmpBitmapDecoder.cs
- LinqDataSourceContextEventArgs.cs
- ProcessHostServerConfig.cs
- ResourceManager.cs
- RoutedEvent.cs
- ParenExpr.cs
- FlowDocumentPageViewerAutomationPeer.cs
- ClassImporter.cs
- ReversePositionQuery.cs
- RsaSecurityTokenAuthenticator.cs
- QueryResponse.cs
- PointLight.cs
- XmlNodeReader.cs