Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / 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; } } } }Indicates whether an HttpNotImplementedHandler instance can be recycled and /// used for another request. ///
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
- XamlParser.cs
- TimestampInformation.cs
- AnonymousIdentificationModule.cs
- WorkflowValidationFailedException.cs
- DispatcherExceptionFilterEventArgs.cs
- WebPartEditorApplyVerb.cs
- HttpListenerRequestTraceRecord.cs
- DiagnosticStrings.cs
- WebEvents.cs
- ControlUtil.cs
- UnknownWrapper.cs
- AsyncResult.cs
- CompatibleComparer.cs
- CompensationToken.cs
- WebPartConnectionsCancelEventArgs.cs
- WsdlEndpointConversionContext.cs
- QuestionEventArgs.cs
- ToolStripOverflowButton.cs
- DataQuery.cs
- coordinatorfactory.cs
- NewExpression.cs
- MediaEntryAttribute.cs
- DetailsView.cs
- DayRenderEvent.cs
- ISAPIWorkerRequest.cs
- CompensationDesigner.cs
- ViewStateChangedEventArgs.cs
- DelegateTypeInfo.cs
- ViewCellSlot.cs
- WindowsAuthenticationEventArgs.cs
- InternalConfigHost.cs
- DependsOnAttribute.cs
- StreamInfo.cs
- EdmType.cs
- XmlSchemaAnyAttribute.cs
- RijndaelManagedTransform.cs
- MenuItemBinding.cs
- TreeNodeClickEventArgs.cs
- SignedPkcs7.cs
- BaseProcessor.cs
- SQLMembershipProvider.cs
- DataObjectMethodAttribute.cs
- DataGridGeneralPage.cs
- InputMethodStateTypeInfo.cs
- FormsAuthenticationEventArgs.cs
- BitmapEffectGeneralTransform.cs
- LeafCellTreeNode.cs
- Transform3DCollection.cs
- ExtensionSimplifierMarkupObject.cs
- XmlIncludeAttribute.cs
- BitmapDownload.cs
- EarlyBoundInfo.cs
- XmlSchemaNotation.cs
- EmptyStringExpandableObjectConverter.cs
- DependencyObjectPropertyDescriptor.cs
- GeneralTransform2DTo3DTo2D.cs
- RotationValidation.cs
- ProcessHost.cs
- GridViewCellAutomationPeer.cs
- ToolStripGrip.cs
- DesignerVerbToolStripMenuItem.cs
- DataObject.cs
- DispatcherEventArgs.cs
- DataRelation.cs
- TypeGeneratedEventArgs.cs
- GridViewCommandEventArgs.cs
- XmlNodeWriter.cs
- FontDriver.cs
- TextCollapsingProperties.cs
- FixedFindEngine.cs
- AcceleratedTokenProviderState.cs
- CornerRadiusConverter.cs
- PointKeyFrameCollection.cs
- GeometryCombineModeValidation.cs
- AdministrationHelpers.cs
- ViewBase.cs
- Base64Decoder.cs
- ArrayConverter.cs
- MemberExpression.cs
- DurableInstanceProvider.cs
- DbProviderFactoriesConfigurationHandler.cs
- CollectionViewGroup.cs
- BlockUIContainer.cs
- PenContexts.cs
- TemplateInstanceAttribute.cs
- TraceRecord.cs
- PathParser.cs
- ProfilePropertyNameValidator.cs
- HGlobalSafeHandle.cs
- Module.cs
- DataTrigger.cs
- LocatorManager.cs
- QueueException.cs
- CallbackHandler.cs
- ToolStripStatusLabel.cs
- DependencyPropertyDescriptor.cs
- UInt16.cs
- XamlStyleSerializer.cs
- BasicHttpBindingElement.cs
- WebPartDescription.cs