API declarations for Call Handover.

Design doc:
https://docs.google.com/document/d/1qY3oAzjff_4A1ttYb_CGrE_OwTRmXMG_KGsIuPT1ey8/edit#

Bug: 65415068
Test: manual.
Change-Id: I0c2f561d92ad6504f858eadde09980fc1ce8727f
This commit is contained in:
Sanket Padawe
2017-11-03 11:07:35 -07:00
parent 62893396bd
commit a8eddd48c4
10 changed files with 208 additions and 7 deletions

View File

@@ -2032,6 +2032,43 @@ public abstract class ConnectionService extends Service {
return null;
}
/**
* Called by Telecom on the initiating side of the handover to create an instance of a
* handover connection.
* @param fromPhoneAccountHandle {@link PhoneAccountHandle} associated with the
* ConnectionService which needs to handover the call.
* @param request Details about the call which needs to be handover.
* @return Connection object corresponding to the handover call.
*/
public Connection onCreateOutgoingHandoverConnection(PhoneAccountHandle fromPhoneAccountHandle,
ConnectionRequest request) {
return null;
}
/**
* Called by Telecom on the receiving side of the handover to request the
* {@link ConnectionService} to create an instance of a handover connection.
* @param fromPhoneAccountHandle {@link PhoneAccountHandle} associated with the
* ConnectionService which needs to handover the call.
* @param request Details about the call which needs to be handover.
* @return {@link Connection} object corresponding to the handover call.
*/
public Connection onCreateIncomingHandoverConnection(PhoneAccountHandle fromPhoneAccountHandle,
ConnectionRequest request) {
return null;
}
/**
* Called by Telecom in response to a {@code TelecomManager#acceptHandover()}
* invocation which failed.
* @param request Details about the call which needs to be handover.
* @param error Reason for handover failure as defined in
* {@link android.telecom.Call.Callback#HANDOVER_FAILURE_DEST_INVALID_PERM}
*/
public void onHandoverFailed(ConnectionRequest request, int error) {
return;
}
/**
* Create a {@code Connection} for a new unknown call. An unknown call is a call originating
* from the ConnectionService that was neither a user-initiated outgoing call, nor an incoming