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
- TcpClientChannel.cs
- SafeMemoryMappedFileHandle.cs
- PeerMessageDispatcher.cs
- ProcessHostConfigUtils.cs
- HostingPreferredMapPath.cs
- ADMembershipUser.cs
- CompiledQuery.cs
- XmlHierarchicalDataSourceView.cs
- IsolatedStorage.cs
- EndpointAddress10.cs
- ExtenderControl.cs
- XmlSchemaGroup.cs
- XhtmlBasicLinkAdapter.cs
- ObjectDataSourceFilteringEventArgs.cs
- SelectionItemProviderWrapper.cs
- PanelStyle.cs
- IndexedString.cs
- HttpPostServerProtocol.cs
- EllipseGeometry.cs
- SqlComparer.cs
- LinqExpressionNormalizer.cs
- OutputCacheProfileCollection.cs
- X509AudioLogo.cs
- XmlNullResolver.cs
- ControlOperationBehavior.cs
- ResourceAttributes.cs
- FrameworkTemplate.cs
- GPPOINT.cs
- XmlReflectionMember.cs
- DesignerActionVerbItem.cs
- HostedBindingBehavior.cs
- Variant.cs
- _HelperAsyncResults.cs
- IndentedTextWriter.cs
- DataGridColumnDropSeparator.cs
- ViewGenerator.cs
- Wizard.cs
- SmiTypedGetterSetter.cs
- mediaeventargs.cs
- SamlAuthorityBinding.cs
- TreeViewCancelEvent.cs
- ToolStripItemTextRenderEventArgs.cs
- DataGridViewTopRowAccessibleObject.cs
- DataProtection.cs
- WindowsClaimSet.cs
- DataGridRow.cs
- KoreanCalendar.cs
- DateTimeFormat.cs
- RadioButtonPopupAdapter.cs
- DefaultWorkflowLoaderService.cs
- ContractsBCL.cs
- RTLAwareMessageBox.cs
- FilterUserControlBase.cs
- PointLight.cs
- SmiSettersStream.cs
- BulletDecorator.cs
- CodeTypeMember.cs
- OleDbMetaDataFactory.cs
- FamilyCollection.cs
- AssociativeAggregationOperator.cs
- XmlEncodedRawTextWriter.cs
- DataSourceSelectArguments.cs
- ScriptResourceAttribute.cs
- TemplateEditingVerb.cs
- DataGridViewButtonColumn.cs
- TemplateContent.cs
- WindowsListViewItemCheckBox.cs
- OpenTypeLayoutCache.cs
- XmlSchemaSequence.cs
- SelectedCellsCollection.cs
- FutureFactory.cs
- itemelement.cs
- ResourceReader.cs
- DocumentXmlWriter.cs
- EventLogException.cs
- TextElementEnumerator.cs
- MediaCommands.cs
- StrongNamePublicKeyBlob.cs
- Win32.cs
- DataSourceXmlSubItemAttribute.cs
- PolyLineSegment.cs
- XpsResource.cs
- StrokeCollection.cs
- ResourcesChangeInfo.cs
- FigureParagraph.cs
- HostSecurityManager.cs
- CatalogPartCollection.cs
- MetafileHeader.cs
- AutomationPropertyInfo.cs
- SqlMetaData.cs
- ActionMessageFilter.cs
- Profiler.cs
- WindowPattern.cs
- TransactionManager.cs
- SafeReversePInvokeHandle.cs
- HideDisabledControlAdapter.cs
- OleDbConnectionFactory.cs
- MonikerProxyAttribute.cs
- Range.cs
- LineSegment.cs