Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / SimpleHandlerFactory.cs / 1305376 / SimpleHandlerFactory.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Handler Factory implementation for ASP.NET files * * Copyright (c) 2000 Microsoft Corporation */ namespace System.Web.UI { using System; using System.Web.Compilation; using Debug = System.Web.Util.Debug; /* * Handler Factory implementation for ASP.NET files */ internal class SimpleHandlerFactory : IHttpHandlerFactory2 { internal SimpleHandlerFactory() { } public virtual IHttpHandler GetHandler(HttpContext context, string requestType, string virtualPath, string path) { // This should never get called //Debug.Assert(false); return ((IHttpHandlerFactory2)this).GetHandler(context, requestType, VirtualPath.CreateNonRelative(virtualPath), path); } IHttpHandler IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) { BuildResultCompiledType result = (BuildResultCompiledType)BuildManager.GetVPathBuildResult( context, virtualPath); // Make sure the type has the correct base class (ASURT 123677) Util.CheckAssignableType(typeof(IHttpHandler), result.ResultType); return (IHttpHandler) result.CreateInstance(); } public virtual void ReleaseHandler(IHttpHandler handler) { } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Handler Factory implementation for ASP.NET files * * Copyright (c) 2000 Microsoft Corporation */ namespace System.Web.UI { using System; using System.Web.Compilation; using Debug = System.Web.Util.Debug; /* * Handler Factory implementation for ASP.NET files */ internal class SimpleHandlerFactory : IHttpHandlerFactory2 { internal SimpleHandlerFactory() { } public virtual IHttpHandler GetHandler(HttpContext context, string requestType, string virtualPath, string path) { // This should never get called //Debug.Assert(false); return ((IHttpHandlerFactory2)this).GetHandler(context, requestType, VirtualPath.CreateNonRelative(virtualPath), path); } IHttpHandler IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) { BuildResultCompiledType result = (BuildResultCompiledType)BuildManager.GetVPathBuildResult( context, virtualPath); // Make sure the type has the correct base class (ASURT 123677) Util.CheckAssignableType(typeof(IHttpHandler), result.ResultType); return (IHttpHandler) result.CreateInstance(); } public virtual void ReleaseHandler(IHttpHandler handler) { } } } // 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
- UIElementIsland.cs
- OleDbError.cs
- TextSelectionProcessor.cs
- DataPagerFieldItem.cs
- DbConnectionClosed.cs
- IssuanceLicense.cs
- NGCSerializerAsync.cs
- AssociationSet.cs
- MessageQueuePermissionEntryCollection.cs
- Parallel.cs
- Exceptions.cs
- MetadataSource.cs
- XmlSchemaGroupRef.cs
- TaskFileService.cs
- DiscoveryClientRequestChannel.cs
- SchemaHelper.cs
- CaseCqlBlock.cs
- ValidatorAttribute.cs
- StreamInfo.cs
- UIAgentCrashedException.cs
- StringUtil.cs
- UserControlDesigner.cs
- Site.cs
- ManagementNamedValueCollection.cs
- Attributes.cs
- OAVariantLib.cs
- TextParagraphProperties.cs
- XmlCountingReader.cs
- ZipIOModeEnforcingStream.cs
- HttpModuleAction.cs
- VisualBrush.cs
- WebPartZone.cs
- MsmqIntegrationSecurity.cs
- Int16AnimationBase.cs
- MasterPageParser.cs
- HtmlInputPassword.cs
- SharedDp.cs
- ICspAsymmetricAlgorithm.cs
- ScrollPattern.cs
- Pair.cs
- DBSchemaTable.cs
- CodeDirectoryCompiler.cs
- EndpointAddressMessageFilter.cs
- Storyboard.cs
- DefaultPropertiesToSend.cs
- PersonalizationDictionary.cs
- TextPointerBase.cs
- WindowsRichEditRange.cs
- ConfigurationStrings.cs
- SiteMapNodeCollection.cs
- ControlTemplate.cs
- ScriptHandlerFactory.cs
- FixedTextBuilder.cs
- DBDataPermission.cs
- GridEntry.cs
- GPPOINTF.cs
- cache.cs
- PenContext.cs
- UIElementParagraph.cs
- PrivilegeNotHeldException.cs
- DocumentScope.cs
- WebResourceUtil.cs
- CreateRefExpr.cs
- StateRuntime.cs
- VBCodeProvider.cs
- Pointer.cs
- TextPointerBase.cs
- OleDbErrorCollection.cs
- HttpDebugHandler.cs
- PermissionSetEnumerator.cs
- ParallelEnumerable.cs
- Encoding.cs
- ResizeGrip.cs
- ExtenderControl.cs
- RTTrackingProfile.cs
- TemplateParser.cs
- Marshal.cs
- TimelineClockCollection.cs
- HtmlInputSubmit.cs
- SecurityContext.cs
- Win32PrintDialog.cs
- ErrorWebPart.cs
- WebMessageEncoderFactory.cs
- EdgeModeValidation.cs
- UInt16Storage.cs
- ObjectNavigationPropertyMapping.cs
- PathSegment.cs
- CodeIterationStatement.cs
- HttpWriter.cs
- Misc.cs
- SqlUtil.cs
- DesignerTransaction.cs
- CuspData.cs
- UInt64Storage.cs
- FactoryGenerator.cs
- Nodes.cs
- UnauthorizedAccessException.cs
- PersonalizableTypeEntry.cs
- ValueOfAction.cs
- ObsoleteAttribute.cs