-
Notifications
You must be signed in to change notification settings - Fork 157
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
138 additions
and
2 deletions.
There are no files selected for viewing
Binary file renamed
BIN
+26.1 MB
OpenIM-SDK/libs/v3.3.1-rc.8.aar → OpenIM-SDK/libs/v3.4.1-alpha.4.aar
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
OpenIM-SDK/src/main/java/io/openim/android/sdk/listener/OnSignalingListener.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
package io.openim.android.sdk.listener; | ||
|
||
import io.openim.android.sdk.models.CustomSignalingInfo; | ||
import io.openim.android.sdk.models.MeetingStreamEvent; | ||
import io.openim.android.sdk.models.RoomCallingInfo; | ||
import io.openim.android.sdk.models.SignalingInfo; | ||
|
||
public interface OnSignalingListener { | ||
|
||
void onInvitationCancelled(SignalingInfo s); | ||
|
||
void onInvitationTimeout(SignalingInfo s); | ||
|
||
void onInviteeAccepted(SignalingInfo s); | ||
|
||
void onInviteeAcceptedByOtherDevice(SignalingInfo s); | ||
|
||
void onInviteeRejected(SignalingInfo s); | ||
|
||
void onInviteeRejectedByOtherDevice(SignalingInfo s); | ||
|
||
void onReceiveNewInvitation(SignalingInfo s); | ||
|
||
void onHangup(SignalingInfo s); | ||
|
||
void onRoomParticipantConnected(RoomCallingInfo s); | ||
|
||
void onRoomParticipantDisconnected(RoomCallingInfo s); | ||
|
||
void onMeetingStreamChanged(MeetingStreamEvent e); | ||
|
||
void onReceiveCustomSignal(CustomSignalingInfo s); | ||
|
||
void onStreamChange(String s); | ||
} |
100 changes: 100 additions & 0 deletions
100
OpenIM-SDK/src/main/java/io/openim/android/sdk/listener/_SignalingListener.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
package io.openim.android.sdk.listener; | ||
|
||
|
||
import io.openim.android.sdk.models.CustomSignalingInfo; | ||
import io.openim.android.sdk.models.MeetingStreamEvent; | ||
import io.openim.android.sdk.models.RoomCallingInfo; | ||
import io.openim.android.sdk.models.SignalingInfo; | ||
import io.openim.android.sdk.utils.CommonUtil; | ||
import io.openim.android.sdk.utils.JsonUtil; | ||
|
||
final public class _SignalingListener implements open_im_sdk_callback.OnSignalingListener { | ||
private final OnSignalingListener listener; | ||
|
||
public _SignalingListener(OnSignalingListener listener) { | ||
this.listener = listener; | ||
} | ||
|
||
@Override | ||
public void onHangUp(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onHangup(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInvitationCancelled(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInvitationCancelled(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInvitationTimeout(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInvitationTimeout(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInviteeAccepted(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInviteeAccepted(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInviteeAcceptedByOtherDevice(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInviteeAcceptedByOtherDevice(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInviteeRejected(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInviteeRejected(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInviteeRejectedByOtherDevice(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onInviteeRejectedByOtherDevice(info)); | ||
} | ||
} | ||
|
||
|
||
@Override | ||
public void onReceiveNewInvitation(String s) { | ||
if (listener != null) { | ||
SignalingInfo info = JsonUtil.toObj(s, SignalingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onReceiveNewInvitation(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onRoomParticipantConnected(String s) { | ||
if (listener != null) { | ||
RoomCallingInfo info = JsonUtil.toObj(s, RoomCallingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onRoomParticipantConnected(info)); | ||
} | ||
} | ||
|
||
@Override | ||
public void onRoomParticipantDisconnected(String s) { | ||
if (listener != null) { | ||
RoomCallingInfo info = JsonUtil.toObj(s, RoomCallingInfo.class); | ||
CommonUtil.runMainThread(() -> listener.onRoomParticipantDisconnected(info)); | ||
} | ||
} | ||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
rootProject.name = "OpenIM-Android" | ||
//include ':app' | ||
include ':app' | ||
include ':OpenIM-SDK' | ||
//include ':pkglib' | ||
include ':pkglib' |