|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mockserver.proxy.http.HttpProxyBuilder
public class HttpProxyBuilder
This class should be used to configure the HttpProxy, using this class is the simplest way to create an HttpProxy instance
| Constructor Summary | |
|---|---|
HttpProxyBuilder()
|
|
| Method Summary | |
|---|---|
HttpProxy |
build()
Build an instance of the HttpProxy |
Thread |
buildAndReturnThread()
Build an instance of the HttpProxy |
HttpProxyBuilder |
withDirect(Integer fromPort,
String toHost,
Integer toPort)
Configure a direct proxy that forwards all requests on the fromPort to the toHost and toPort |
HttpProxyBuilder |
withDirectSSL(Integer fromSecurePort,
String toHost,
Integer toPort)
Configure a secure direct proxy that forwards all requests on the fromSecurePort to the toHost and toPort using SSL |
HttpProxyBuilder |
withHTTPPort(Integer port)
Configure HTTP port for proxy, setting this value will ensure HTTP is supported |
HttpProxyBuilder |
withHTTPSPort(Integer securePort)
Configure HTTP/SSL (HTTPS) port for proxy, setting this value will ensure HTTPS is supported, clients that use HTTP -> HTTPS CONNECT request also require the HTTP port to be set using HttpProxyBuilder#withHTTPPort(Integer port) |
HttpProxyBuilder |
withSOCKSPort(Integer socksPort)
Configure SOCKS port for proxy, setting this value will ensure SOCKS is supported Note: currently clients using SSL after connecting with SOCKS are not current supported |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HttpProxyBuilder()
| Method Detail |
|---|
public HttpProxyBuilder withHTTPPort(Integer port)
port - the HTTP port to usepublic HttpProxyBuilder withHTTPSPort(Integer securePort)
securePort - the HTTP/SSL (HTTPS) port to usepublic HttpProxyBuilder withSOCKSPort(Integer socksPort)
socksPort - the SOCKS port to use
public HttpProxyBuilder withDirect(Integer fromPort,
String toHost,
Integer toPort)
fromPort - the local proxy port for direct forwardingtoHost - the destination hostname for direct forwardingtoPort - the destination port for direct forwarding
public HttpProxyBuilder withDirectSSL(Integer fromSecurePort,
String toHost,
Integer toPort)
fromSecurePort - the local proxy port for direct forwarding over SSLtoHost - the destination hostname for direct forwardingtoPort - the destination port for direct forwardingpublic HttpProxy build()
public Thread buildAndReturnThread()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||