Commit a1961faa authored by Sylvain Berfini's avatar Sylvain Berfini 🎩
Browse files

Added JNI getFrom to LinphoneChatMessage

parent 239e4f55
...@@ -1425,10 +1425,15 @@ extern "C" void Java_org_linphone_core_LinphoneChatMessageImpl_setExternalBodyUr ...@@ -1425,10 +1425,15 @@ extern "C" void Java_org_linphone_core_LinphoneChatMessageImpl_setExternalBodyUr
linphone_chat_message_set_external_body_url((LinphoneChatMessage *)ptr, url); linphone_chat_message_set_external_body_url((LinphoneChatMessage *)ptr, url);
env->ReleaseStringUTFChars(jurl, url); env->ReleaseStringUTFChars(jurl, url);
} }
extern "C" long Java_org_linphone_core_LinphoneChatMessageImpl_getPeerAddress(JNIEnv* env extern "C" jlong Java_org_linphone_core_LinphoneChatMessageImpl_getFrom(JNIEnv* env
,jobject thiz ,jobject thiz
,jlong ptr) { ,jlong ptr) {
return (long) linphone_chat_message_get_peer_address((LinphoneChatMessage*)ptr); return (jlong) linphone_chat_message_get_from((LinphoneChatMessage*)ptr);
}
extern "C" jlong Java_org_linphone_core_LinphoneChatMessageImpl_getPeerAddress(JNIEnv* env
,jobject thiz
,jlong ptr) {
return (jlong) linphone_chat_message_get_peer_address((LinphoneChatMessage*)ptr);
} }
extern "C" void Java_org_linphone_core_LinphoneChatRoomImpl_sendMessage(JNIEnv* env extern "C" void Java_org_linphone_core_LinphoneChatRoomImpl_sendMessage(JNIEnv* env
,jobject thiz ,jobject thiz
......
...@@ -74,6 +74,13 @@ public interface LinphoneChatMessage { ...@@ -74,6 +74,13 @@ public interface LinphoneChatMessage {
*/ */
LinphoneAddress getPeerAddress(); LinphoneAddress getPeerAddress();
/**
* get from address associated to this LinphoneChatMessage
*
* @return LinphoneAddress from address
*/
LinphoneAddress getFrom();
/** /**
* Linphone message can carry external body as defined by rfc2017 * Linphone message can carry external body as defined by rfc2017
* @param message #LinphoneChatMessage * @param message #LinphoneChatMessage
......
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