Package com.intuit.karate.http
Class HttpUtils
java.lang.Object
com.intuit.karate.http.HttpUtils
- Author:
- pthomas3
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidaddViaHeader(io.netty.handler.codec.http.HttpMessage msg, String alias) static io.netty.handler.codec.http.FullHttpResponsestatic io.netty.handler.codec.http.FullHttpResponsecreateResponse(int status, String body) static io.netty.handler.codec.http.FullHttpResponsecreateResponse(io.netty.handler.codec.http.HttpResponseStatus status, String body) static voidcreateSelfSignedCertificate(File cert, File key) static voidfixHeadersForProxy(io.netty.handler.codec.http.HttpRequest request) static voidflushAndClose(io.netty.channel.Channel ch) static SSLContextgetSslContext(File keyStoreFile) static FileinitKeyStore(File keyStoreFile) static StringnormaliseUriPath(String uri) static CharsetparseContentTypeCharset(String mimeType) parseContentTypeParams(String mimeType) static StringUtils.PairparseUriIntoUrlBaseAndPath(String rawUri) parseUriPattern(String pattern, String url) static io.netty.handler.codec.http.FullHttpResponse
-
Method Details
-
parseContentTypeCharset
-
parseContentTypeParams
-
parseUriPattern
-
normaliseUriPath
-
parseUriIntoUrlBaseAndPath
-
flushAndClose
public static void flushAndClose(io.netty.channel.Channel ch) -
createSelfSignedCertificate
-
getSslContext
-
initKeyStore
-
createResponse
-
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
-