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 / HTTPNotFoundHandler.cs / 1 / HTTPNotFoundHandler.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Synchronous Http request handler interface * * Copyright (c) 1998 Microsoft Corporation */ namespace System.Web { ////// internal class HttpNotFoundHandler : IHttpHandler { internal HttpNotFoundHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { PerfCounters.IncrementCounter(AppPerfCounter.REQUESTS_NOT_FOUND); throw new HttpException(404, SR.GetString(SR.Path_not_found, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } internal class HttpForbiddenHandler : IHttpHandler { internal HttpForbiddenHandler() { } ///Indicates whether an HttpNotFoundHandler instance can be recycled and used /// for another request. ////// public void ProcessRequest(HttpContext context) { PerfCounters.IncrementCounter(AppPerfCounter.REQUESTS_NOT_FOUND); throw new HttpException(403, SR.GetString(SR.Path_forbidden, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } ///Indicates whether an HttpForbiddenHandler instance can be recycled and used /// for another request. ////// internal class HttpMethodNotAllowedHandler : IHttpHandler { internal HttpMethodNotAllowedHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { throw new HttpException(405, SR.GetString(SR.Path_forbidden, context.Request.HttpMethod)); } ///Drives /// web processing execution. ////// public bool IsReusable { get { return true; } } } ///Indicates whether an HttpForbiddenHandler instance can be recycled and used /// for another request. ////// internal class HttpNotImplementedHandler : IHttpHandler { internal HttpNotImplementedHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { throw new HttpException(501, SR.GetString(SR.Method_for_path_not_implemented, context.Request.HttpMethod, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //Indicates whether an HttpNotImplementedHandler instance can be recycled and /// used for another request. ///// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * Synchronous Http request handler interface * * Copyright (c) 1998 Microsoft Corporation */ namespace System.Web { ////// internal class HttpNotFoundHandler : IHttpHandler { internal HttpNotFoundHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { PerfCounters.IncrementCounter(AppPerfCounter.REQUESTS_NOT_FOUND); throw new HttpException(404, SR.GetString(SR.Path_not_found, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } internal class HttpForbiddenHandler : IHttpHandler { internal HttpForbiddenHandler() { } ///Indicates whether an HttpNotFoundHandler instance can be recycled and used /// for another request. ////// public void ProcessRequest(HttpContext context) { PerfCounters.IncrementCounter(AppPerfCounter.REQUESTS_NOT_FOUND); throw new HttpException(403, SR.GetString(SR.Path_forbidden, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } ///Indicates whether an HttpForbiddenHandler instance can be recycled and used /// for another request. ////// internal class HttpMethodNotAllowedHandler : IHttpHandler { internal HttpMethodNotAllowedHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { throw new HttpException(405, SR.GetString(SR.Path_forbidden, context.Request.HttpMethod)); } ///Drives /// web processing execution. ////// public bool IsReusable { get { return true; } } } ///Indicates whether an HttpForbiddenHandler instance can be recycled and used /// for another request. ////// internal class HttpNotImplementedHandler : IHttpHandler { internal HttpNotImplementedHandler() { } ///Provides a synchronous Http request handler interface. ////// public void ProcessRequest(HttpContext context) { throw new HttpException(501, SR.GetString(SR.Method_for_path_not_implemented, context.Request.HttpMethod, context.Request.Path)); } ///Drives web processing execution. ////// public bool IsReusable { get { return true; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Indicates whether an HttpNotImplementedHandler instance can be recycled and /// used for another request. ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SecurityException.cs
- CatalogZoneBase.cs
- DrawItemEvent.cs
- RequestCachingSection.cs
- ScrollViewerAutomationPeer.cs
- BoundingRectTracker.cs
- ISessionStateStore.cs
- HtmlInputPassword.cs
- CompModHelpers.cs
- StylusEditingBehavior.cs
- ResizeBehavior.cs
- Misc.cs
- WebEventTraceProvider.cs
- DefaultBinder.cs
- HttpResponseHeader.cs
- PersonalizationEntry.cs
- UndoManager.cs
- SqlSelectClauseBuilder.cs
- PolyBezierSegment.cs
- MimeMapping.cs
- RepeaterCommandEventArgs.cs
- RecordManager.cs
- CatalogPartChrome.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- ThicknessConverter.cs
- PlatformCulture.cs
- AvTraceDetails.cs
- CategoryNameCollection.cs
- TreeBuilder.cs
- UniqueEventHelper.cs
- TextSelectionHelper.cs
- DocumentViewerHelper.cs
- ConfigurationStrings.cs
- ServiceBehaviorAttribute.cs
- XmlMembersMapping.cs
- OperationCanceledException.cs
- IndependentlyAnimatedPropertyMetadata.cs
- Calendar.cs
- CheckBoxField.cs
- LinkedList.cs
- _AutoWebProxyScriptHelper.cs
- OpenTypeLayout.cs
- TemplatedEditableDesignerRegion.cs
- BeginStoryboard.cs
- SetUserPreferenceRequest.cs
- FtpWebResponse.cs
- DataSet.cs
- SmiMetaData.cs
- Message.cs
- SelectionEditor.cs
- ProfileService.cs
- GridSplitter.cs
- WorkflowService.cs
- hwndwrapper.cs
- RowSpanVector.cs
- TableLayoutPanelCellPosition.cs
- odbcmetadatacollectionnames.cs
- AnnotationObservableCollection.cs
- ConfigurationManagerInternalFactory.cs
- RegexGroupCollection.cs
- RemotingServices.cs
- EntityConnectionStringBuilderItem.cs
- ValidationRule.cs
- ValidationPropertyAttribute.cs
- Converter.cs
- WebPartConnectVerb.cs
- FormViewUpdateEventArgs.cs
- FastEncoder.cs
- TraceSection.cs
- RowBinding.cs
- CompilerScopeManager.cs
- Panel.cs
- DoubleCollectionConverter.cs
- IriParsingElement.cs
- ScrollViewer.cs
- RawKeyboardInputReport.cs
- GridViewColumnCollectionChangedEventArgs.cs
- XmlCollation.cs
- IPAddress.cs
- DurableOperationAttribute.cs
- PrePrepareMethodAttribute.cs
- CalculatedColumn.cs
- RemoteCryptoRsaServiceProvider.cs
- HostedBindingBehavior.cs
- SoapSchemaExporter.cs
- TextParagraph.cs
- PersonalizationProviderCollection.cs
- EncodingTable.cs
- SocketAddress.cs
- LocatorBase.cs
- XmlElementAttributes.cs
- FusionWrap.cs
- SuppressIldasmAttribute.cs
- UndoEngine.cs
- KnownTypeAttribute.cs
- MeshGeometry3D.cs
- DataGridLinkButton.cs
- RepeatButton.cs
- TextFindEngine.cs
- CommaDelimitedStringAttributeCollectionConverter.cs