Skip to content
This repository was archived by the owner on Nov 24, 2020. It is now read-only.

Commit f87d8b9

Browse files
add setHttpClient method on android target
1 parent cf1f457 commit f87d8b9

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

sdkgen

1.74 MB
Binary file not shown.

sdkgen.dwarf

628 KB
Binary file not shown.

src/target/java_android.cr

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,10 @@ END
351351
return Internal.getHttpClient();
352352
}
353353
354+
static public void setHttpClient(OkHttpClient newClient) {
355+
Internal.setHttpClient(newClient);
356+
}
357+
354358
static public void setApiUrl(String url) {
355359
Internal.forcedUrl = url;
356360
}
@@ -428,6 +432,10 @@ END
428432
return http;
429433
}
430434
435+
static void setHttpClient(OkHttpClient newClient) {
436+
http = newClient;
437+
}
438+
431439
static void createHttpClient() {
432440
connectionPool = new ConnectionPool(100, 45, TimeUnit.SECONDS);
433441

0 commit comments

Comments
 (0)