--- a/src/java.net.http/share/classes/java/net/http/HttpResponse.java Tue Feb 13 14:34:00 2018 +0000
+++ b/src/java.net.http/share/classes/java/net/http/HttpResponse.java Tue Feb 13 14:42:41 2018 +0000
@@ -373,8 +373,8 @@
* // and accumulates lines that match a particular pattern
* Pattern pattern = ...;
* LineParserSubscriber subscriber = new LineParserSubscriber(pattern);
- * HttpResponse<List<String>> response = client.sendAsync(request,
- * BodyHandler.fromLineSubscriber(subscriber, (s) -> s.getMatchingLines(), "\n")).join();
+ * HttpResponse<List<String>> response = client.send(request,
+ * BodyHandler.fromLineSubscriber(subscriber, s -> s.getMatchingLines(), "\n"));
* if (response.statusCode() != 200) {
* System.err.printf("ERROR: %d status received%n", response.statusCode());
* } }</pre>