TestServer.CreateHandler 方法

定义

重载

CreateHandler()

创建用于通过测试服务器处理 HTTP 请求/响应的自定义 HttpMessageHandler

CreateHandler(Action<HttpContext>)

使用测试服务器的自定义配置创建用于处理 HTTP 请求/响应的自定义 HttpMessageHandler

CreateHandler()

Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs

创建用于通过测试服务器处理 HTTP 请求/响应的自定义 HttpMessageHandler

public:
 System::Net::Http::HttpMessageHandler ^ CreateHandler();
public System.Net.Http.HttpMessageHandler CreateHandler ();
member this.CreateHandler : unit -> System.Net.Http.HttpMessageHandler
Public Function CreateHandler () As HttpMessageHandler

返回

适用于

CreateHandler(Action<HttpContext>)

Source:
TestServer.cs
Source:
TestServer.cs
Source:
TestServer.cs

使用测试服务器的自定义配置创建用于处理 HTTP 请求/响应的自定义 HttpMessageHandler

public System.Net.Http.HttpMessageHandler CreateHandler (Action<Microsoft.AspNetCore.Http.HttpContext> additionalContextConfiguration);
member this.CreateHandler : Action<Microsoft.AspNetCore.Http.HttpContext> -> System.Net.Http.HttpMessageHandler
Public Function CreateHandler (additionalContextConfiguration As Action(Of HttpContext)) As HttpMessageHandler

参数

additionalContextConfiguration
Action<HttpContext>

返回

适用于