Class Connectors

java.lang.Object
io.undertow.server.Connectors

public class Connectors extends Object
This class provides the connector part of the HttpServerExchange API.

It contains methods that logically belong on the exchange, however should only be used by connector implementations.

Author:
Stuart Douglas
  • Constructor Details

    • Connectors

      public Connectors()
  • Method Details

    • flattenCookies

      public static void flattenCookies(HttpServerExchange exchange)
      Flattens the exchange cookie map into the response header map. This should be called by a connector just before the response is started.
      Parameters:
      exchange - The server exchange
    • isRunningHandlerChain

      public static boolean isRunningHandlerChain(HttpServerExchange exchange)
    • ungetRequestBytes

      public static void ungetRequestBytes(HttpServerExchange exchange, io.netty.buffer.ByteBuf buffer)
      Attached buffered data to the exchange. The will generally be used to allow data to be re-read.
      Parameters:
      exchange - The HTTP server exchange
      buffer - The buffers to attach
    • setRequestStartTime

      public static void setRequestStartTime(HttpServerExchange exchange)
    • setRequestStartTime

      public static void setRequestStartTime(HttpServerExchange existing, HttpServerExchange newExchange)
    • executeRootHandler

      public static void executeRootHandler(HttpHandler handler, HttpServerExchange exchange)
    • setExchangeRequestPath

      @Deprecated public static void setExchangeRequestPath(HttpServerExchange exchange, String encodedPath, String charset, boolean decode, boolean allowEncodedSlash, StringBuilder decodeBuffer)
      Deprecated.
      Sets the request path and query parameters, decoding to the requested charset.
      Parameters:
      exchange - The exchange
      encodedPath - The encoded path
      charset - The charset
    • setExchangeRequestPath

      public static void setExchangeRequestPath(HttpServerExchange exchange, String encodedPath, String charset, boolean decode, boolean allowEncodedSlash, StringBuilder decodeBuffer, int maxParameters) throws ParameterLimitException
      Sets the request path and query parameters, decoding to the requested charset.
      Parameters:
      exchange - The exchange
      encodedPath - The encoded path
      charset - The charset
      Throws:
      ParameterLimitException