Class HttpUtils

java.lang.Object
com.intuit.karate.http.HttpUtils

public class HttpUtils extends Object
Author:
pthomas3
  • Method Details

    • parseContentTypeCharset

      public static Charset parseContentTypeCharset(String mimeType)
    • parseContentTypeParams

      public static Map<String,String> parseContentTypeParams(String mimeType)
    • parseUriPattern

      public static Map<String,String> parseUriPattern(String pattern, String url)
    • normaliseUriPath

      public static String normaliseUriPath(String uri)
    • parseUriIntoUrlBaseAndPath

      public static StringUtils.Pair parseUriIntoUrlBaseAndPath(String rawUri)
    • flushAndClose

      public static void flushAndClose(io.netty.channel.Channel ch)
    • createSelfSignedCertificate

      public static void createSelfSignedCertificate(File cert, File key)
    • getSslContext

      public static SSLContext getSslContext(File keyStoreFile)
    • initKeyStore

      public static File initKeyStore(File keyStoreFile)
    • createResponse

      public static io.netty.handler.codec.http.FullHttpResponse createResponse(int status, String body)
    • createResponse

      public static io.netty.handler.codec.http.FullHttpResponse createResponse(io.netty.handler.codec.http.HttpResponseStatus status, String body)
    • transform

      public static io.netty.handler.codec.http.FullHttpResponse transform(io.netty.handler.codec.http.FullHttpResponse original, String body)
    • connectionEstablished

      public static io.netty.handler.codec.http.FullHttpResponse connectionEstablished()
    • fixHeadersForProxy

      public static void fixHeadersForProxy(io.netty.handler.codec.http.HttpRequest request)
    • addViaHeader

      public static void addViaHeader(io.netty.handler.codec.http.HttpMessage msg, String alias)