public final class TkProxy extends Object implements Take
The class is immutable and thread-safe.
public TkProxy(URI tgt)
tgt
- Target to which requests are forwardedpublic TkProxy(String tgt)
tgt
- Target to which requests are forwardedpublic TkProxy(String tgt, String mark)
tgt
- Target to which requests are forwardedmark
- Marker (text label) to add to the HTTP headerpublic TkProxy(URI tgt, String mark)
The target
parameter takes the destination URL
to which requests are proxied. Some valid examples:
http://example.com
http://www.example.com
https://example.com:8080
https://example.com/x/y
tgt
- Target to which requests are forwardedmark
- Marker (text label) to add to the HTTP headerpublic Response act(Request req) throws IOException
Take
act
in interface Take
req
- Request to processIOException
- If failsCopyright © 2015–2018 Take. All rights reserved.