Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / untmp / whidbey / QFE / ndp / fx / src / xsp / System / Web / Configuration / WebBaseEventKeyComparer.cs / 1 / WebBaseEventKeyComparer.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.Globalization; using System.IO; using System.Text; using System.ComponentModel; using System.Web.Hosting; using System.Web.Util; using System.Web.Configuration; using System.Web.Management; using System.Web.Compilation; internal class WebBaseEventKeyComparer : IEqualityComparer { public new bool Equals(object x, object y) { CustomWebEventKey xKey = (CustomWebEventKey)x; CustomWebEventKey yKey = (CustomWebEventKey)y; if (xKey._eventCode == yKey._eventCode && xKey._type.Equals(yKey._type)) { return true; } return false; } public int GetHashCode(object obj) { return ((CustomWebEventKey)obj)._eventCode ^ ((CustomWebEventKey)obj)._type.GetHashCode(); } public int Compare(object x, object y) { CustomWebEventKey xKey = (CustomWebEventKey)x; CustomWebEventKey yKey = (CustomWebEventKey)y; int xEventCode = xKey._eventCode; int yEventCode = yKey._eventCode; if (xEventCode == yEventCode) { Type xType = xKey._type; Type yType = yKey._type; if (xType.Equals(yType)) { return 0; } else { return Comparer.Default.Compare(xType.ToString(), yType.ToString()); } } else { if (xEventCode > yEventCode) { return 1; } else { return -1; } } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Border.cs
- OperationFormatUse.cs
- CryptographicAttribute.cs
- PropertyMapper.cs
- MonikerHelper.cs
- ControlBuilder.cs
- TcpHostedTransportConfiguration.cs
- SafeTimerHandle.cs
- HtmlEncodedRawTextWriter.cs
- TimersDescriptionAttribute.cs
- SettingsPropertyValueCollection.cs
- EventPropertyMap.cs
- DSACryptoServiceProvider.cs
- DataSourceSelectArguments.cs
- IPEndPoint.cs
- WebMethodAttribute.cs
- VersionedStream.cs
- DomainUpDown.cs
- WindowsTooltip.cs
- ParseHttpDate.cs
- EnumerableRowCollectionExtensions.cs
- DtdParser.cs
- AuthorizationSection.cs
- DependencySource.cs
- WebPartVerbsEventArgs.cs
- TrimSurroundingWhitespaceAttribute.cs
- EditorPart.cs
- FunctionUpdateCommand.cs
- StatusBar.cs
- UIElement.cs
- LogStore.cs
- BufferedGraphicsManager.cs
- CollectionExtensions.cs
- XamlToRtfWriter.cs
- FragmentQueryKB.cs
- ImageClickEventArgs.cs
- ObjectAnimationUsingKeyFrames.cs
- CanonicalXml.cs
- SystemInfo.cs
- MetadataUtil.cs
- DummyDataSource.cs
- AsyncDataRequest.cs
- CacheManager.cs
- AutomationPatternInfo.cs
- TextBlock.cs
- XmlRawWriter.cs
- XmlChoiceIdentifierAttribute.cs
- Block.cs
- DiffuseMaterial.cs
- Fault.cs
- CodeChecksumPragma.cs
- InheritanceContextHelper.cs
- PolyLineSegmentFigureLogic.cs
- AnimationTimeline.cs
- XslVisitor.cs
- ApplicationSecurityInfo.cs
- wgx_sdk_version.cs
- ServiceBuildProvider.cs
- Html32TextWriter.cs
- TransactionState.cs
- BulletedList.cs
- Mappings.cs
- OrderedDictionary.cs
- PartManifestEntry.cs
- sqlnorm.cs
- MetadataLocation.cs
- SplineQuaternionKeyFrame.cs
- Win32.cs
- _DisconnectOverlappedAsyncResult.cs
- SingleSelectRootGridEntry.cs
- CodeCatchClauseCollection.cs
- TraceFilter.cs
- EntityWithKeyStrategy.cs
- HtmlInputRadioButton.cs
- FacetDescriptionElement.cs
- LinqExpressionNormalizer.cs
- DependentList.cs
- PathFigure.cs
- SemaphoreFullException.cs
- ObsoleteAttribute.cs
- SqlFunctionAttribute.cs
- SoapAttributes.cs
- PersonalizationStateInfoCollection.cs
- SchemaCreator.cs
- SchemaElement.cs
- TextViewSelectionProcessor.cs
- Size3D.cs
- DatatypeImplementation.cs
- TableDetailsRow.cs
- ToolStripContentPanel.cs
- SessionEndingEventArgs.cs
- DocComment.cs
- DesignerOptions.cs
- SpStreamWrapper.cs
- SafeNativeMethods.cs
- ExpandableObjectConverter.cs
- CounterSample.cs
- RangeValuePattern.cs
- RemotingSurrogateSelector.cs
- FormattedTextSymbols.cs