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
- XmlHierarchyData.cs
- UTF32Encoding.cs
- PartDesigner.cs
- AutoCompleteStringCollection.cs
- Token.cs
- DeleteIndexBinder.cs
- FrugalList.cs
- DataGridRow.cs
- ToolStripItemCollection.cs
- FrameworkReadOnlyPropertyMetadata.cs
- contentDescriptor.cs
- TextRangeSerialization.cs
- EditorPart.cs
- HashSet.cs
- DetailsViewPageEventArgs.cs
- sortedlist.cs
- DataGridViewButtonColumn.cs
- XmlIlTypeHelper.cs
- ElementAction.cs
- ExceptionHelpers.cs
- StandardTransformFactory.cs
- HwndSourceKeyboardInputSite.cs
- ProfileProvider.cs
- Rect3DValueSerializer.cs
- SoundPlayer.cs
- GridViewColumnCollectionChangedEventArgs.cs
- PDBReader.cs
- MenuItem.cs
- ReliableOutputConnection.cs
- DbMetaDataFactory.cs
- AttributeUsageAttribute.cs
- _Connection.cs
- Constants.cs
- followingquery.cs
- XmlQueryTypeFactory.cs
- ICspAsymmetricAlgorithm.cs
- JavaScriptObjectDeserializer.cs
- ConvertEvent.cs
- ThicknessConverter.cs
- FixedSOMContainer.cs
- HttpClientCertificate.cs
- Visitors.cs
- XmlWriterSettings.cs
- WebBodyFormatMessageProperty.cs
- Authorization.cs
- RectangleF.cs
- ScaleTransform3D.cs
- UnsafeNativeMethods.cs
- URIFormatException.cs
- CodeStatementCollection.cs
- DecoderFallback.cs
- PartialToken.cs
- DataGridViewRowConverter.cs
- GenericAuthenticationEventArgs.cs
- DragStartedEventArgs.cs
- EntityDataSourceContextDisposingEventArgs.cs
- SymmetricKeyWrap.cs
- ViewKeyConstraint.cs
- PointLightBase.cs
- TypeUtil.cs
- ServiceModelSecurityTokenTypes.cs
- InvokePattern.cs
- sqlpipe.cs
- ServicesUtilities.cs
- ObjectPersistData.cs
- CodeDelegateCreateExpression.cs
- SchemaMapping.cs
- ReflectionTypeLoadException.cs
- FieldDescriptor.cs
- HostedHttpContext.cs
- XmlSchemaComplexContentRestriction.cs
- connectionpool.cs
- ActivationArguments.cs
- CryptoProvider.cs
- WindowsListViewGroupSubsetLink.cs
- LocatorGroup.cs
- TextServicesProperty.cs
- Config.cs
- CookieParameter.cs
- BamlResourceSerializer.cs
- TextEditorTables.cs
- PolicyUtility.cs
- ReadOnlyDictionary.cs
- ASCIIEncoding.cs
- XmlStringTable.cs
- WMIInterop.cs
- StyleHelper.cs
- MergeFailedEvent.cs
- ConsoleKeyInfo.cs
- AssociationSet.cs
- EventMappingSettingsCollection.cs
- GlobalItem.cs
- StackOverflowException.cs
- WindowsSolidBrush.cs
- ZipIOCentralDirectoryDigitalSignature.cs
- PropertyNames.cs
- Environment.cs
- OperationAbortedException.cs
- LoadRetryConstantStrategy.cs
- ClaimTypes.cs