HttpRequest.Abort 方法
定义
强制地终止基础 TCP 连接,会导致任何显著的 I/O 失败。Forcibly terminates the underlying TCP connection, causing any outstanding I/O to fail. 可使用此方法来响应恶意 HTTP 客户端的攻击。You might use this method in response to an attack by a malicious HTTP client.
public:
void Abort();
public void Abort ();
member this.Abort : unit -> unit
Public Sub Abort ()
注解
此方法是线程安全的。This method is thread-safe. 任何线程都可以随时调用它。Any thread may call it at any time.
此方法只能在集成模式下使用。This method can only be used in integrated mode. 如果在经典模式下调用它,则会引发异常。If you invoke it in classic mode, an exception is thrown. 若要确定管道模式,请使用 UsingIntegratedPipeline 。To determine the pipeline mode, use UsingIntegratedPipeline.