我正在尝试使用LoopJ
,但它给了我一个Header[]
参数上的错误,如下图所示。它说我需要导入Header
包,但是当我这样做时,它给我另一个错误FileAsyncHttpResponseHandler
。LoopJ Header []错误
AsyncHttpClient client = new AsyncHttpClient();
client.get("https://example.com/file.png", new FileAsyncHttpResponseHandler(/* Context */ this) {
@Override
public void onFailure(int i, Header[] headers, Throwable throwable, File file) {
}
@Override
public void onSuccess(int i, Header[] headers, File file) {
}
});