Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / Configuration / HttpHandlersSection.cs / 1 / HttpHandlersSection.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.IO; using System.Text; using System.Web.Util; using System.Web.Compilation; using System.Globalization; using System.Security.Permissions; [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class HttpHandlersSection : ConfigurationSection { private static ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propHandlers = new ConfigurationProperty(null, typeof(HttpHandlerActionCollection), null, ConfigurationPropertyOptions.IsDefaultCollection); private bool _validated; static HttpHandlersSection() { // Property initialization _properties = new ConfigurationPropertyCollection(); _properties.Add(_propHandlers); } public HttpHandlersSection() { } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("", IsDefaultCollection = true)] public HttpHandlerActionCollection Handlers { get { return (HttpHandlerActionCollection)base[_propHandlers]; } } internal bool ValidateHandlers() { if (!_validated) { lock (this) { if (!_validated) { foreach (HttpHandlerAction ha in Handlers) { ha.InitValidateInternal(); } _validated = true; } } } return _validated; } internal HttpHandlerAction FindMapping(String verb, VirtualPath path) { ValidateHandlers(); for (int i = 0; i < Handlers.Count; i++) { HttpHandlerAction m = (HttpHandlerAction)Handlers[i]; if (m.IsMatch(verb, path)) { return m; } } return null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// 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.IO; using System.Text; using System.Web.Util; using System.Web.Compilation; using System.Globalization; using System.Security.Permissions; [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class HttpHandlersSection : ConfigurationSection { private static ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propHandlers = new ConfigurationProperty(null, typeof(HttpHandlerActionCollection), null, ConfigurationPropertyOptions.IsDefaultCollection); private bool _validated; static HttpHandlersSection() { // Property initialization _properties = new ConfigurationPropertyCollection(); _properties.Add(_propHandlers); } public HttpHandlersSection() { } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("", IsDefaultCollection = true)] public HttpHandlerActionCollection Handlers { get { return (HttpHandlerActionCollection)base[_propHandlers]; } } internal bool ValidateHandlers() { if (!_validated) { lock (this) { if (!_validated) { foreach (HttpHandlerAction ha in Handlers) { ha.InitValidateInternal(); } _validated = true; } } } return _validated; } internal HttpHandlerAction FindMapping(String verb, VirtualPath path) { ValidateHandlers(); for (int i = 0; i < Handlers.Count; i++) { HttpHandlerAction m = (HttpHandlerAction)Handlers[i]; if (m.IsMatch(verb, path)) { return m; } } return null; } } } // 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
- DataGridHeaderBorder.cs
- PolicyException.cs
- KeyedCollection.cs
- CalendarDayButton.cs
- ApplicationDirectory.cs
- BlobPersonalizationState.cs
- DataControlLinkButton.cs
- Html32TextWriter.cs
- AppearanceEditorPart.cs
- webeventbuffer.cs
- HttpCookiesSection.cs
- ReceiveActivityDesigner.cs
- PropertyGeneratedEventArgs.cs
- MenuItemBindingCollection.cs
- JsonDeserializer.cs
- AuthorizationContext.cs
- AssemblyUtil.cs
- ServiceBusyException.cs
- PropertyStore.cs
- NavigationHelper.cs
- SerializationInfoEnumerator.cs
- GlobalAclOperationRequirement.cs
- MetadataSource.cs
- PagesSection.cs
- WindowsListViewItem.cs
- InvokeWebService.cs
- ConfigurationStrings.cs
- MultiAsyncResult.cs
- ColumnCollectionEditor.cs
- MarkupProperty.cs
- TdsParserSafeHandles.cs
- AdapterDictionary.cs
- HtmlMeta.cs
- ScrollBar.cs
- PerformanceCounterPermission.cs
- LineServicesRun.cs
- ClientTargetSection.cs
- IndexedString.cs
- CaseInsensitiveHashCodeProvider.cs
- ToolBarButtonClickEvent.cs
- CommentAction.cs
- ImageCreator.cs
- RichTextBoxConstants.cs
- EntityDataSourceContainerNameItem.cs
- ChannelSinkStacks.cs
- WebPartDisplayMode.cs
- StringUtil.cs
- DeclaredTypeElement.cs
- SessionStateModule.cs
- Int32CAMarshaler.cs
- TextSerializer.cs
- ListViewGroupConverter.cs
- UnmanagedBitmapWrapper.cs
- TimestampInformation.cs
- ProxyHwnd.cs
- Positioning.cs
- DbReferenceCollection.cs
- SQLInt16Storage.cs
- XmlSchemaException.cs
- WpfWebRequestHelper.cs
- OwnerDrawPropertyBag.cs
- RelOps.cs
- PageCatalogPartDesigner.cs
- BypassElementCollection.cs
- DocumentViewerBase.cs
- CaseInsensitiveOrdinalStringComparer.cs
- PrintDialogException.cs
- InstalledVoice.cs
- PermissionSet.cs
- ExtractCollection.cs
- NotifyCollectionChangedEventArgs.cs
- DragEventArgs.cs
- DetailsViewPageEventArgs.cs
- GeometryModel3D.cs
- WeakReferenceKey.cs
- OleDbConnectionPoolGroupProviderInfo.cs
- XomlCompiler.cs
- ComponentCollection.cs
- EncodingNLS.cs
- XhtmlStyleClass.cs
- ActivationArguments.cs
- OneOfScalarConst.cs
- CalendarBlackoutDatesCollection.cs
- PrincipalPermission.cs
- Debug.cs
- Byte.cs
- HtmlInputFile.cs
- WebPartConnectionsCloseVerb.cs
- PathGradientBrush.cs
- HashSet.cs
- StrongNameMembershipCondition.cs
- DragCompletedEventArgs.cs
- ProvideValueServiceProvider.cs
- IOThreadScheduler.cs
- DropDownList.cs
- XPathNode.cs
- GcHandle.cs
- RegistrySecurity.cs
- SqlMultiplexer.cs
- ScrollProperties.cs