From 8b4818d9b4d632f2d460e7ac9dea463b04db43fe Mon Sep 17 00:00:00 2001 From: Sailesh Nepal Date: Fri, 6 Jun 2014 10:54:07 -0700 Subject: [PATCH] API: Add call service handoff trigger Change-Id: Iee03a666e7ebc2fe326f32405174466299be9d04 --- api/current.txt | 1 + .../java/android/telecomm/CallServiceAdapter.java | 12 ++++++++++++ .../internal/telecomm/ICallServiceAdapter.aidl | 2 ++ 3 files changed, 15 insertions(+) diff --git a/api/current.txt b/api/current.txt index eab14e2c06731..178d7497b6e78 100644 --- a/api/current.txt +++ b/api/current.txt @@ -27601,6 +27601,7 @@ package android.telecomm { public final class CallServiceAdapter { method public void handleFailedOutgoingCall(android.telecomm.ConnectionRequest, int, java.lang.String); method public void handleSuccessfulOutgoingCall(java.lang.String); + method public void handoffCall(java.lang.String); method public void notifyIncomingCall(android.telecomm.CallInfo); method public void onPostDialWait(java.lang.String, java.lang.String); method public void setActive(java.lang.String); diff --git a/telecomm/java/android/telecomm/CallServiceAdapter.java b/telecomm/java/android/telecomm/CallServiceAdapter.java index fb5c87160c74a..8c3ddad3c670b 100644 --- a/telecomm/java/android/telecomm/CallServiceAdapter.java +++ b/telecomm/java/android/telecomm/CallServiceAdapter.java @@ -224,4 +224,16 @@ public final class CallServiceAdapter { } catch (RemoteException ignored) { } } + + /** + * Instructs Telecomm to handoff the call to another call service. + * + * @param callId The identifier of the call to handoff. + */ + public void handoffCall(String callId) { + try { + mAdapter.handoffCall(callId); + } catch (RemoteException e) { + } + } } diff --git a/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl b/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl index 17e04879bba08..b380293f8dc83 100644 --- a/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl +++ b/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl @@ -54,4 +54,6 @@ oneway interface ICallServiceAdapter { void removeCall(String callId); void onPostDialWait(String callId, String remaining); + + void handoffCall(String callId); }