HTTPServerResponse.switchToHTTP2

Special method sending a SWITCHING_PROTOCOLS response to the client.

Notice: For the overload that returns a ConnectionStream, it must be ensured that the returned instance doesn't outlive the request handler callback.

  1. ConnectionStream switchProtocol(string protocol)
  2. void switchProtocol(string protocol, void delegate(scope ConnectionStream) @(safe) del)
  3. void switchToHTTP2(HANDLER handler, HTTP2ServerContext context)
    struct HTTPServerResponse
    package @safe @safe
    void
    switchToHTTP2
    (
    HANDLER
    )
    (
    HANDLER handler
    ,
    HTTP2ServerContext context
    )

Meta