diff options
author | Scott Lobdell <slobdell@google.com> | 2020-10-07 16:24:43 -0700 |
---|---|---|
committer | Justin DeMartino <jjdemartino@google.com> | 2020-10-09 12:51:22 -0700 |
commit | 27e7f8c2aa4ce0a2f59b3bf1969b06bfd1e9ebca (patch) | |
tree | 3834c14dc757e958d5fa4fdfa19921b0294d8d99 /telecomm/java/android/telecom/ConnectionService.java | |
parent | 540b11039841c20b63ade118ffece7c9e65797c1 (diff) | |
parent | 199180c357078db5598e00e20ceccc6c20c93cb5 (diff) |
Merge SP1A.200921.001
Change-Id: I6a8d7215f874fed05e9fec71b17c8a3d1e2c94e0
Diffstat (limited to 'telecomm/java/android/telecom/ConnectionService.java')
-rwxr-xr-x | telecomm/java/android/telecom/ConnectionService.java | 53 |
1 files changed, 44 insertions, 9 deletions
diff --git a/telecomm/java/android/telecom/ConnectionService.java b/telecomm/java/android/telecom/ConnectionService.java index 3efab17874e9..78a5056762e2 100755 --- a/telecomm/java/android/telecom/ConnectionService.java +++ b/telecomm/java/android/telecom/ConnectionService.java @@ -1880,6 +1880,7 @@ public abstract class ConnectionService extends Service { mConferenceById.put(callId, conference); mIdByConference.put(conference, callId); + conference.addListener(mConferenceListener); ParcelableConference parcelableConference = new ParcelableConference.Builder( request.getAccountHandle(), conference.getState()) @@ -2491,6 +2492,42 @@ public abstract class ConnectionService extends Service { } /** + * Ask some other {@code ConnectionService} to create a {@code RemoteConference} given an + * incoming request. This is used by {@code ConnectionService}s that are registered with + * {@link PhoneAccount#CAPABILITY_ADHOC_CONFERENCE_CALLING}. + * + * @param connectionManagerPhoneAccount See description at + * {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}. + * @param request Details about the incoming conference call. + * @return The {@code RemoteConference} object to satisfy this call, or {@code null} to not + * handle the call. + */ + public final @Nullable RemoteConference createRemoteIncomingConference( + @Nullable PhoneAccountHandle connectionManagerPhoneAccount, + @Nullable ConnectionRequest request) { + return mRemoteConnectionManager.createRemoteConference(connectionManagerPhoneAccount, + request, true); + } + + /** + * Ask some other {@code ConnectionService} to create a {@code RemoteConference} given an + * outgoing request. This is used by {@code ConnectionService}s that are registered with + * {@link PhoneAccount#CAPABILITY_ADHOC_CONFERENCE_CALLING}. + * + * @param connectionManagerPhoneAccount See description at + * {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}. + * @param request Details about the outgoing conference call. + * @return The {@code RemoteConference} object to satisfy this call, or {@code null} to not + * handle the call. + */ + public final @Nullable RemoteConference createRemoteOutgoingConference( + @Nullable PhoneAccountHandle connectionManagerPhoneAccount, + @Nullable ConnectionRequest request) { + return mRemoteConnectionManager.createRemoteConference(connectionManagerPhoneAccount, + request, false); + } + + /** * Indicates to the relevant {@code RemoteConnectionService} that the specified * {@link RemoteConnection}s should be merged into a conference call. * <p> @@ -2682,15 +2719,15 @@ public abstract class ConnectionService extends Service { return null; } /** - * Create a {@code Connection} given an incoming request. This is used to attach to existing - * incoming conference call. + * Create a {@code Conference} given an incoming request. This is used to attach to an incoming + * conference call initiated via + * {@link TelecomManager#addNewIncomingConference(PhoneAccountHandle, Bundle)}. * * @param connectionManagerPhoneAccount See description at * {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}. - * @param request Details about the incoming call. - * @return The {@code Connection} object to satisfy this call, or {@code null} to + * @param request Details about the incoming conference call. + * @return The {@code Conference} object to satisfy this call, or {@code null} to * not handle the call. - * @hide */ public @Nullable Conference onCreateIncomingConference( @Nullable PhoneAccountHandle connectionManagerPhoneAccount, @@ -2775,7 +2812,6 @@ public abstract class ConnectionService extends Service { * @param connectionManagerPhoneAccount See description at * {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}. * @param request The incoming connection request. - * @hide */ public void onCreateIncomingConferenceFailed( @Nullable PhoneAccountHandle connectionManagerPhoneAccount, @@ -2796,7 +2832,6 @@ public abstract class ConnectionService extends Service { * @param connectionManagerPhoneAccount See description at * {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}. * @param request The outgoing connection request. - * @hide */ public void onCreateOutgoingConferenceFailed( @Nullable PhoneAccountHandle connectionManagerPhoneAccount, @@ -2845,7 +2880,8 @@ public abstract class ConnectionService extends Service { /** * Create a {@code Conference} given an outgoing request. This is used to initiate new - * outgoing conference call. + * outgoing conference call requested via + * {@link TelecomManager#startConference(List, Bundle)}. * * @param connectionManagerPhoneAccount The connection manager account to use for managing * this call. @@ -2865,7 +2901,6 @@ public abstract class ConnectionService extends Service { * @param request Details about the outgoing call. * @return The {@code Conference} object to satisfy this call, or the result of an invocation * of {@link Connection#createFailedConnection(DisconnectCause)} to not handle the call. - * @hide */ public @Nullable Conference onCreateOutgoingConference( @Nullable PhoneAccountHandle connectionManagerPhoneAccount, |