Commit 7e436c72 authored by Sylvain Berfini's avatar Sylvain Berfini
Browse files

Updated ms2 + added wrapped migration to multi transport method in JNI

parent c7f8b5aa
......@@ -779,6 +779,12 @@ extern "C" void Java_org_linphone_core_LinphoneCoreImpl_delete(JNIEnv* env
delete lcData;
}
extern "C" jint Java_org_linphone_core_LinphoneCoreImpl_migrateToMultiTransport(JNIEnv* env
,jobject thiz
,jlong lc) {
return (jint) linphone_core_migrate_to_multi_transport((LinphoneCore *)lc);
}
/*
* Class: org_linphone_core_LinphoneCoreImpl
* Method: createInfoMessage
......
......@@ -1463,4 +1463,14 @@ public interface LinphoneCore {
* @return an array of String
*/
public String[] getSupportedVideoSizes();
/**
* Migrate configuration so that all SIP transports are enabled.
* Versions of linphone < 3.7 did not support using multiple SIP transport simultaneously.
* This function helps application to migrate the configuration so that all transports are enabled.
* Existing proxy configuration are added a transport parameter so that they continue using the unique transport that was set previously.
* This function must be used just after creating the core, before any call to linphone_core_iterate()
* @returns 1 if migration was done, 0 if not done because unnecessary or already done, -1 in case of error.
*/
public int migrateToMultiTransport();
}
......@@ -144,6 +144,7 @@ class LinphoneCoreImpl implements LinphoneCore {
private native String getPrimaryContactDisplayName(long nativePtr);
private native void setChatDatabasePath(long nativePtr, String path);
private native long[] getChatRooms(long nativePtr);
private native int migrateToMultiTransport(long nativePtr);
LinphoneCoreImpl(LinphoneCoreListener listener, File userConfig, File factoryConfig, Object userdata) throws IOException {
mListener = listener;
......@@ -396,10 +397,12 @@ class LinphoneCoreImpl implements LinphoneCore {
addFriend(nativePtr,((LinphoneFriendImpl)lf).nativePtr);
}
@SuppressWarnings("deprecation")
public synchronized void setPresenceInfo(int minutes_away, String alternative_contact, OnlineStatus status) {
setPresenceInfo(nativePtr,minutes_away,alternative_contact,status.mValue);
}
@SuppressWarnings("deprecation")
public synchronized OnlineStatus getPresenceInfo() {
return OnlineStatus.fromInt(getPresenceInfo(nativePtr));
}
......@@ -1094,4 +1097,9 @@ class LinphoneCoreImpl implements LinphoneCore {
public String[] getSupportedVideoSizes() {
return listSupportedVideoResolutions(nativePtr);
}
@Override
public int migrateToMultiTransport() {
return migrateToMultiTransport(nativePtr);
}
}
mediastreamer2 @ 1de47782
Subproject commit c4fd2eea1e49cb102327670a122a177e08a7f206
Subproject commit 1de47782b0598594d8c6c55e9ff641da51326719
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment