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
- ChildDocumentBlock.cs
- Canvas.cs
- View.cs
- GenericWebPart.cs
- Utils.cs
- FragmentQueryKB.cs
- CalendarBlackoutDatesCollection.cs
- DesignBindingValueUIHandler.cs
- Normalization.cs
- _ReceiveMessageOverlappedAsyncResult.cs
- SqlCacheDependencyDatabaseCollection.cs
- ScrollBarRenderer.cs
- QuaternionAnimation.cs
- EnvelopeVersion.cs
- HtmlTableRow.cs
- _Semaphore.cs
- CommonXSendMessage.cs
- DataGridToolTip.cs
- BamlTreeUpdater.cs
- SspiNegotiationTokenAuthenticatorState.cs
- MethodAccessException.cs
- TreeViewBindingsEditor.cs
- DropTarget.cs
- AssemblyCache.cs
- IgnoreSectionHandler.cs
- NativeActivityFaultContext.cs
- ObjectSet.cs
- Win32Interop.cs
- XDRSchema.cs
- GZipDecoder.cs
- NamedPipeTransportBindingElement.cs
- DetailsViewPageEventArgs.cs
- DbMetaDataColumnNames.cs
- ToolConsole.cs
- ManagedWndProcTracker.cs
- RoutedEventValueSerializer.cs
- XmlDataCollection.cs
- ProgressPage.cs
- TagPrefixInfo.cs
- MimeReturn.cs
- WebPartManager.cs
- OleDbFactory.cs
- CharacterHit.cs
- NameValueFileSectionHandler.cs
- TransactionManager.cs
- CustomTrackingRecord.cs
- PartialList.cs
- OpacityConverter.cs
- RijndaelManagedTransform.cs
- RelationshipNavigation.cs
- ContextInformation.cs
- InputBuffer.cs
- TableHeaderCell.cs
- WindowsScroll.cs
- ProbeDuplexCD1AsyncResult.cs
- XmlUnspecifiedAttribute.cs
- WpfXamlType.cs
- KeyInstance.cs
- Vector3D.cs
- Adorner.cs
- ArithmeticException.cs
- DataGridViewAdvancedBorderStyle.cs
- ContractCodeDomInfo.cs
- Axis.cs
- PropertyEmitterBase.cs
- PeerNode.cs
- GcHandle.cs
- Misc.cs
- EventRouteFactory.cs
- BitmapCodecInfo.cs
- TabControlEvent.cs
- ComPersistableTypeElement.cs
- SessionStateUtil.cs
- TcpServerChannel.cs
- ObjectItemAttributeAssemblyLoader.cs
- FocusManager.cs
- ParameterBuilder.cs
- FormatException.cs
- TextLineResult.cs
- OracleBFile.cs
- baseshape.cs
- TextAutomationPeer.cs
- EntityWithChangeTrackerStrategy.cs
- FunctionNode.cs
- BinHexEncoding.cs
- OracleCommand.cs
- NonParentingControl.cs
- ImageIndexConverter.cs
- EventEntry.cs
- _SslState.cs
- SchemaNames.cs
- FunctionImportMapping.ReturnTypeRenameMapping.cs
- TextTreeText.cs
- DataGridViewImageColumn.cs
- StaticExtension.cs
- NativeMethods.cs
- CompilerErrorCollection.cs
- TrustSection.cs
- basecomparevalidator.cs
- SelfIssuedAuthProofToken.cs