aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java')
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java b/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java
index 26854205..8f970a09 100644
--- a/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java
+++ b/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusApplication.java
@@ -10,6 +10,7 @@ import java.io.File;
import java.security.SecureRandom;
import de.duenndns.ssl.MemorizingTrustManager;
+import de.thedevstack.conversationsplus.http.HttpClient;
import de.thedevstack.conversationsplus.http.HttpConnectionManager;
import de.thedevstack.conversationsplus.persistance.FileBackend;
import de.thedevstack.conversationsplus.services.filetransfer.FileTransferManager;
@@ -18,6 +19,7 @@ import de.thedevstack.conversationsplus.services.filetransfer.jingle.JingleFileT
import de.thedevstack.conversationsplus.utils.ImageUtil;
import de.thedevstack.conversationsplus.utils.PRNGFixes;
import de.thedevstack.conversationsplus.utils.SerialSingleThreadExecutor;
+import okhttp3.OkHttpClient;
/**
* This class is used to provide static access to the applicationcontext.
@@ -46,6 +48,7 @@ public class ConversationsPlusApplication extends Application {
FileBackend.init();
FileTransferManager.init(new HttpUploadFileTransferService(), new JingleFileTransferService());
HttpConnectionManager.init();
+ HttpClient.init();
}
/**
@@ -147,6 +150,11 @@ public class ConversationsPlusApplication extends Application {
getInstance().setMemorizingTrustManager(tm);
}
+ private static void initHttpClient() {
+ OkHttpClient client = new OkHttpClient.Builder()
+ .build();
+ }
+
public static SecureRandom getSecureRandom() {
return getInstance().secureRandom;
}