Skip to content

Commit baf17bb

Browse files
committed
AsyncHttpClient is an interface
1 parent fc653a9 commit baf17bb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ You can also mix Future with AsyncHandler to only retrieve part of the asynchron
7373
import org.asynchttpclient.*;
7474
import java.util.concurrent.Future;
7575

76-
AsyncHttpClient asyncHttpClient = new AsyncHttpClient();
76+
AsyncHttpClient asyncHttpClient = new DefaultAsyncHttpClient();
7777
Future<Integer> f = asyncHttpClient.prepareGet("http://www.example.com/").execute(
7878
new AsyncCompletionHandler<Integer>(){
7979

@@ -100,7 +100,7 @@ which is something you want to do for large responses: this way you can process
100100
import org.asynchttpclient.*;
101101
import java.util.concurrent.Future;
102102

103-
AsyncHttpClient c = new AsyncHttpClient();
103+
AsyncHttpClient c = new DefaultAsyncHttpClient();
104104
Future<String> f = c.prepareGet("http://www.example.com/").execute(new AsyncHandler<String>() {
105105
private ByteArrayOutputStream bytes = new ByteArrayOutputStream();
106106

0 commit comments

Comments
 (0)