Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / xsp / System / Web / Configuration / HandlerFactoryWrapper.cs / 2 / HandlerFactoryWrapper.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Config related classes for HttpApplication */ namespace System.Web.Configuration { using System; using System.Web.Util; /* * Single instance handler factory */ internal class HandlerFactoryWrapper : IHttpHandlerFactory { private IHttpHandler _handler; private Type _handlerType; internal HandlerFactoryWrapper(IHttpHandler handler, Type handlerType) { _handler = handler; _handlerType = handlerType; } public IHttpHandler GetHandler(HttpContext context, String requestType, String url, String pathTranslated) { if (_handler == null) _handler = (IHttpHandler)HttpRuntime.CreateNonPublicInstance(_handlerType); return _handler; } public void ReleaseHandler(IHttpHandler handler) { Debug.Assert(handler == _handler); if (_handler != null && !_handler.IsReusable) _handler = null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Config related classes for HttpApplication */ namespace System.Web.Configuration { using System; using System.Web.Util; /* * Single instance handler factory */ internal class HandlerFactoryWrapper : IHttpHandlerFactory { private IHttpHandler _handler; private Type _handlerType; internal HandlerFactoryWrapper(IHttpHandler handler, Type handlerType) { _handler = handler; _handlerType = handlerType; } public IHttpHandler GetHandler(HttpContext context, String requestType, String url, String pathTranslated) { if (_handler == null) _handler = (IHttpHandler)HttpRuntime.CreateNonPublicInstance(_handlerType); return _handler; } public void ReleaseHandler(IHttpHandler handler) { Debug.Assert(handler == _handler); if (_handler != null && !_handler.IsReusable) _handler = null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
![Network programming in C#, Network Programming in VB.NET, Network Programming in .NET](/images/book.jpg)
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DataServiceException.cs
- BaseTemplateBuildProvider.cs
- FunctionNode.cs
- QilGenerator.cs
- MemberBinding.cs
- DataPagerFieldItem.cs
- SessionSwitchEventArgs.cs
- PagesSection.cs
- GeometryDrawing.cs
- oledbmetadatacolumnnames.cs
- FontDialog.cs
- EntityReference.cs
- FixedSOMLineRanges.cs
- SignedXml.cs
- BigInt.cs
- Margins.cs
- HtmlImage.cs
- TokenBasedSet.cs
- ReflectionHelper.cs
- EntityWrapper.cs
- EncoderParameters.cs
- PTUtility.cs
- TokenBasedSet.cs
- DataGridRowAutomationPeer.cs
- BehaviorEditorPart.cs
- ListViewHitTestInfo.cs
- RegistryKey.cs
- InstanceCreationEditor.cs
- CodeBlockBuilder.cs
- TableItemPattern.cs
- MissingManifestResourceException.cs
- CodeRegionDirective.cs
- DataSourceComponent.cs
- Transform.cs
- SamlAuthorizationDecisionClaimResource.cs
- ConfigXmlElement.cs
- WebServiceErrorEvent.cs
- RtfFormatStack.cs
- SqlDependencyListener.cs
- BitmapEffectGroup.cs
- BaseContextMenu.cs
- LinqDataView.cs
- TraceSource.cs
- CommonGetThemePartSize.cs
- TabControlAutomationPeer.cs
- ContentControl.cs
- PartitionResolver.cs
- Pair.cs
- NamedPipeAppDomainProtocolHandler.cs
- CodeValidator.cs
- CodeSnippetExpression.cs
- SqlDataSourceStatusEventArgs.cs
- PropertyCollection.cs
- DataGridTextColumn.cs
- ConnectionPointCookie.cs
- WrappedOptions.cs
- AppDomainShutdownMonitor.cs
- Int32Rect.cs
- RegisteredExpandoAttribute.cs
- ComponentRenameEvent.cs
- CacheDependency.cs
- SqlDataSourceStatusEventArgs.cs
- HandlerMappingMemo.cs
- RootBuilder.cs
- UnrecognizedPolicyAssertionElement.cs
- mediaeventshelper.cs
- XmlElementAttribute.cs
- MappedMetaModel.cs
- SHA384Managed.cs
- XmlNotation.cs
- ResXResourceReader.cs
- FilteredDataSetHelper.cs
- IxmlLineInfo.cs
- ProfileManager.cs
- ToolStripSplitButton.cs
- CookielessHelper.cs
- CleanUpVirtualizedItemEventArgs.cs
- DataGridViewImageCell.cs
- Exceptions.cs
- SystemException.cs
- NumberFormatter.cs
- QuaternionAnimation.cs
- SecurityStandardsManager.cs
- XmlNode.cs
- ProfileSettingsCollection.cs
- EnglishPluralizationService.cs
- RoleManagerModule.cs
- storepermission.cs
- TimeEnumHelper.cs
- RoleManagerSection.cs
- OracleInfoMessageEventArgs.cs
- PeerNameResolver.cs
- Vars.cs
- XPathEmptyIterator.cs
- SynchronizedInputHelper.cs
- UnsafeNativeMethods.cs
- Control.cs
- _ShellExpression.cs
- XmlSchemaSimpleTypeUnion.cs
- ProgressBarAutomationPeer.cs