add section about ftp urls to proxy doc

Signed-off-by: alexlehm <alexlehm@gmail.com>
This commit is contained in:
alexlehm
2017-04-29 12:34:13 +02:00
parent 9e19df7f49
commit e77a258fc6
3 changed files with 43 additions and 1 deletions

View File

@@ -765,6 +765,17 @@ public class HTTPExamples {
}
public void example60(Vertx vertx) {
HttpClientOptions options = new HttpClientOptions()
.setProxyOptions(new ProxyOptions().setType(ProxyType.HTTP));
HttpClient client = vertx.createHttpClient(options);
client.getAbs("ftp://ftp.gnu.org/gnu/", response -> {
System.out.println("Received response with status code " + response.statusCode());
});
}
public void serversharing(Vertx vertx) {
vertx.createHttpServer().requestHandler(request -> {
request.response().end("Hello from server " + this);