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
- FrameSecurityDescriptor.cs
- SafeLibraryHandle.cs
- WebPartUserCapability.cs
- TdsValueSetter.cs
- DataGrid.cs
- HashStream.cs
- BitmapEffect.cs
- SequentialActivityDesigner.cs
- XamlInt32CollectionSerializer.cs
- XPathItem.cs
- ReachBasicContext.cs
- WriteFileContext.cs
- RequiredFieldValidator.cs
- QfeChecker.cs
- BindingManagerDataErrorEventArgs.cs
- PageContentCollection.cs
- MSAAWinEventWrap.cs
- LinqDataSourceDeleteEventArgs.cs
- FormView.cs
- TraceLog.cs
- MergeLocalizationDirectives.cs
- COAUTHINFO.cs
- PingReply.cs
- FormViewPageEventArgs.cs
- MetadataItemSerializer.cs
- MsmqIntegrationAppDomainProtocolHandler.cs
- GlobalizationSection.cs
- MethodBuilder.cs
- HttpHandlerAction.cs
- XmlSchemaElement.cs
- VisualTreeUtils.cs
- NumberFormatInfo.cs
- SqlBooleanMismatchVisitor.cs
- CryptographicAttribute.cs
- ProcessHostFactoryHelper.cs
- Pkcs7Signer.cs
- RequestCacheEntry.cs
- Int32Storage.cs
- ManifestResourceInfo.cs
- ElementNotEnabledException.cs
- SqlSelectStatement.cs
- ReaderWriterLock.cs
- PrintPreviewGraphics.cs
- ApplicationProxyInternal.cs
- CompModSwitches.cs
- _AutoWebProxyScriptHelper.cs
- XpsS0ValidatingLoader.cs
- Padding.cs
- XmlAtomicValue.cs
- StatusBarDrawItemEvent.cs
- RtfToXamlLexer.cs
- DynamicControlParameter.cs
- AccessControlEntry.cs
- MethodMessage.cs
- SignedXml.cs
- ObjectStorage.cs
- DependencyObjectType.cs
- TablePattern.cs
- QualifiedCellIdBoolean.cs
- HashMembershipCondition.cs
- ValidationErrorCollection.cs
- LogSwitch.cs
- panel.cs
- FixedBufferAttribute.cs
- VarRemapper.cs
- EventRouteFactory.cs
- ToolStripArrowRenderEventArgs.cs
- CuspData.cs
- ping.cs
- ConditionalAttribute.cs
- ClosableStream.cs
- XmlCharacterData.cs
- SessionStateSection.cs
- WMIInterop.cs
- ShaderEffect.cs
- X509CertificateStore.cs
- XsltConvert.cs
- OleDbParameter.cs
- ComboBoxDesigner.cs
- NativeCompoundFileAPIs.cs
- HttpRequestCacheValidator.cs
- UInt16.cs
- CollectionBuilder.cs
- RegexParser.cs
- RSAPKCS1SignatureDeformatter.cs
- SecurityCredentialsManager.cs
- XmlUtf8RawTextWriter.cs
- DbSourceParameterCollection.cs
- RelativeSource.cs
- TableRow.cs
- dtdvalidator.cs
- DiagnosticTrace.cs
- ScriptHandlerFactory.cs
- XamlBrushSerializer.cs
- ConnectionStringSettings.cs
- EventLogEntryCollection.cs
- ImageAnimator.cs
- SharedMemory.cs
- GridSplitterAutomationPeer.cs
- SqlDataSourceView.cs