summaryrefslogtreecommitdiffstats
path: root/telecomm/java/com/android/internal
diff options
context:
space:
mode:
Diffstat (limited to 'telecomm/java/com/android/internal')
-rw-r--r--telecomm/java/com/android/internal/telecomm/ICallService.aidl104
-rw-r--r--telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl66
-rw-r--r--telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl58
-rw-r--r--telecomm/java/com/android/internal/telecomm/IInCallService.aidl58
4 files changed, 33 insertions, 253 deletions
diff --git a/telecomm/java/com/android/internal/telecomm/ICallService.aidl b/telecomm/java/com/android/internal/telecomm/ICallService.aidl
index 3455efd..cc0641c 100644
--- a/telecomm/java/com/android/internal/telecomm/ICallService.aidl
+++ b/telecomm/java/com/android/internal/telecomm/ICallService.aidl
@@ -23,126 +23,36 @@ import android.telecomm.CallInfo;
import com.android.internal.telecomm.ICallServiceAdapter;
/**
- * Service interface for services which would like to provide calls to be
- * managed by the system in-call UI.
+ * Internal remote interface for call services.
*
- * This interface provides methods that the android framework can use to deliver commands
- * for calls provided by this call service including making new calls and disconnecting
- * existing ones. A binding to ICallService implementations exists for two conditions:
- * 1) There exists one or more live calls for that call service,
- * 2) Prior to an outbound call to test if this call service is compatible with the outgoing call.
+ * @see android.telecomm.CallService
*
- * TODO(santoscordon): Need final public-facing comments in this file.
- * {@hide}
+ * @hide
*/
oneway interface ICallService {
-
- /**
- * Sets an implementation of ICallServiceAdapter which the call service can use to add new calls
- * and communicate state changes of existing calls. This is the first method that is called
- * after the framework binds to the call service.
- *
- * @param callServiceAdapter Interface to CallsManager for adding and updating calls.
- */
void setCallServiceAdapter(in ICallServiceAdapter callServiceAdapter);
- /**
- * Determines if the ICallService can place the specified call. Response is sent via
- * {@link ICallServiceAdapter#setCompatibleWith}. When responding, the correct call ID must be
- * specified. It is expected that the call service respond within 500 milliseconds. Any response
- * that takes longer than 500 milliseconds will be treated as being incompatible.
- * TODO(santoscordon): 500 ms was arbitrarily chosen and must be confirmed before this
- * API is made public. Only used in the context of outgoing calls and call switching (handoff).
- *
- * @param callInfo The details of the relevant call.
- */
void isCompatibleWith(in CallInfo callInfo);
- /**
- * Attempts to call the relevant party using the specified call's handle, be it a phone number,
- * SIP address, or some other kind of user ID. Note that the set of handle types is
- * dynamically extensible since call providers should be able to implement arbitrary
- * handle-calling systems. See {@link #isCompatibleWith}. It is expected that the
- * call service respond via {@link ICallServiceAdapter#handleSuccessfulOutgoingCall} if it can
- * successfully make the call. Only used in the context of outgoing calls.
- * TODO(santoscordon): Figure out how a call service can short-circuit a failure to the adapter.
- *
- * @param callInfo The details of the relevant call.
- */
void call(in CallInfo callInfo);
- /**
- * Aborts the outgoing call attempt. Invoked in the unlikely event that Telecomm decides to
- * abort an attempt to place a call. Only ever be invoked after {@link #call} invocations.
- * After this is invoked, Telecomm does not expect any more updates about the call and will
- * actively ignore any such update. This is different from {@link #disconnect} where Telecomm
- * expects confirmation via ICallServiceAdapter.markCallAsDisconnected.
- *
- * @param callId The identifier of the call to abort.
- */
void abort(String callId);
- /**
- * Receives a new call ID to use with an incoming call. Invoked by Telecomm after it is notified
- * that this call service has a pending incoming call, see
- * {@link TelecommConstants#ACTION_INCOMING_CALL}. The call service must first give Telecomm
- * additional information of the call through {@link ICallServiceAdapter#handleIncomingCall}.
- * Following that, the call service can update the call at will using the specified call ID.
- *
- * As part of the {@link TelecommConstants#ACTION_INCOMING_CALL} Intent, a Bundle of extra
- * data could be sent via {@link TelecommConstants#EXTRA_INCOMING_CALL_EXTRAS}, which is
- * returned through this method. If no data was given, an empty Bundle will be returned.
- *
- * @param callId The ID of the call.
- * @param extras The Bundle of extra information passed via
- * {@link TelecommConstants#EXTRA_INCOMING_CALL_EXTRAS}.
- */
void setIncomingCallId(String callId, in Bundle extras);
- /**
- * Answers a ringing call identified by callId. Telecomm invokes this method as a result of the
- * user hitting the "answer" button in the incoming call screen.
- *
- * @param callId The ID of the call.
- */
void answer(String callId);
- /**
- * Rejects a ringing call identified by callId. Telecomm invokes this method as a result of the
- * user hitting the "reject" button in the incoming call screen.
- *
- * @param callId The ID of the call.
- */
void reject(String callId);
- /**
- * Disconnects the call identified by callId. Used for outgoing and incoming calls.
- *
- * @param callId The identifier of the call to disconnect.
- */
void disconnect(String callId);
- /**
- * Puts the call identified by callId on hold. Telecomm invokes this method when a call should
- * be placed on hold per user request or because a different call was made active.
- *
- * @param callId The identifier of the call to put on hold.
- */
void hold(String callId);
- /**
- * Removes the call identified by callId from hold. Telecomm invokes this method when a call
- * should be removed on hold per user request or because a different call was put on hold.
- *
- * @param callId The identifier of the call to remove from hold.
- */
void unhold(String callId);
- /**
- * Called when the audio state changes.
- *
- * @param activeCallId The identifier of the call that was active during the state change.
- * @param audioState The new {@link CallAudioState}.
- */
void onAudioStateChanged(String activeCallId, in CallAudioState audioState);
+
+ void playDtmfTone(String callId, char digit);
+
+ void stopDtmfTone(String callId);
}
diff --git a/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl b/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl
index bbf4e80..dfdaa75 100644
--- a/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl
+++ b/telecomm/java/com/android/internal/telecomm/ICallServiceAdapter.aidl
@@ -19,86 +19,28 @@ package com.android.internal.telecomm;
import android.telecomm.CallInfo;
/**
- * Provides methods for ICallService implementations to interact with the system phone app.
- * TODO(santoscordon): Need final public-facing comments in this file.
+ * Internal remote callback interface for call services.
+ *
+ * @see android.telecomm.CallServiceAdapter
+ *
* {@hide}
*/
oneway interface ICallServiceAdapter {
-
- /**
- * Receives confirmation of a call service's ability to place a call. This method is used in
- * response to {@link ICallService#isCompatibleWith}.
- *
- * @param callId The identifier of the call for which compatibility is being received. This ID
- * should correspond to the ID given as part of the call information in
- * {@link ICallService#isCompatibleWith}.
- * @param isCompatible True if the call service can place the call.
- */
void setIsCompatibleWith(String callId, boolean isCompatible);
- /**
- * Provides Telecomm with the details of an incoming call. An invocation of this method must
- * follow {@link CallService#setIncomingCallId} and use the call ID specified therein. Upon
- * the invocation of this method, Telecomm will bring up the incoming-call interface where the
- * user can elect to answer or reject a call.
- *
- * @param callInfo The details of the relevant call.
- */
void notifyIncomingCall(in CallInfo callInfo);
- /**
- * Tells Telecomm that an attempt to place the specified outgoing call succeeded.
- * TODO(santoscordon): Consider adding a CallState parameter in case this outgoing call is
- * somehow no longer in the DIALING state.
- *
- * @param callId The ID of the outgoing call.
- */
void handleSuccessfulOutgoingCall(String callId);
- /**
- * Tells Telecomm that an attempt to place the specified outgoing call failed.
- *
- * @param callId The ID of the outgoing call.
- * @param errorMessage The error associated with the failed call attempt.
- */
void handleFailedOutgoingCall(String callId, String errorMessage);
- /**
- * Sets a call's state to active (e.g., an ongoing call where two parties can actively
- * communicate).
- *
- * @param callId The unique ID of the call whose state is changing to active.
- */
void setActive(String callId);
- /**
- * Sets a call's state to ringing (e.g., an inbound ringing call).
- *
- * @param callId The unique ID of the call whose state is changing to ringing.
- */
void setRinging(String callId);
- /**
- * Sets a call's state to dialing (e.g., dialing an outbound call).
- *
- * @param callId The unique ID of the call whose state is changing to dialing.
- */
void setDialing(String callId);
- /**
- * Sets a call's state to disconnected.
- *
- * @param callId The unique ID of the call whose state is changing to disconnected.
- * @param disconnectCause The reason for the disconnection, any of
- * {@link android.telephony.DisconnectCause}.
- * @param disconnectMessage The call-service-provided message about the disconnect cause.
- */
void setDisconnected(String callId, int disconnectCause, String disconnectMessage);
- /**
- * Sets a call's state to be on hold.
- *
- * @param callId The unique ID of the call whose state is changing to be on hold.
- */
void setOnHold(String callId);
}
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl b/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
index 0fe3bfc..e0cdb83 100644
--- a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
+++ b/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
@@ -19,68 +19,30 @@ package com.android.internal.telecomm;
import android.telecomm.CallAudioState;
/**
- * Receives commands from {@link IInCallService} implementations which should be executed by
- * Telecomm. When Telecomm binds to a {@link IInCallService}, an instance of this class is given to
- * the in-call service through which it can manipulate live (active, dialing, ringing) calls. When
- * the in-call service is notified of new calls ({@link IInCallService#addCall}), it can use the
- * given call IDs to execute commands such as {@link #answerCall} for incoming calls or
- * {@link #disconnectCall} for active calls the user would like to end. Some commands are only
- * appropriate for calls in certain states; please consult each method for such limitations.
- * TODO(santoscordon): Needs more/better comments once the API is finalized.
- * TODO(santoscordon): Specify the adapter will stop functioning when there are no more calls.
- * TODO(santoscordon): Once we have proper "CallState" constant definitions, consider rewording
- * the javadoc to reference those states precisely.
+ * Internal remote callback interface for in-call services.
+ *
+ * @see android.telecomm.InCallAdapter
+ *
* {@hide}
*/
oneway interface IInCallAdapter {
- /**
- * Instructs Telecomm to answer the specified call.
- *
- * @param callId The identifier of the call to answer.
- */
void answerCall(String callId);
- /**
- * Instructs Telecomm to reject the specified call.
- * TODO(santoscordon): Add reject-with-text-message parameter when that feature
- * is ported over.
- *
- * @param callId The identifier of the call to reject.
- */
void rejectCall(String callId);
- /**
- * Instructs Telecomm to disconnect the specified call.
- *
- * @param callId The identifier of the call to disconnect.
- */
void disconnectCall(String callId);
- /**
- * Instructs Telecomm to put the specified call on hold.
- *
- * @param callId The identifier of the call to put on hold.
- */
void holdCall(String callId);
- /**
- * Instructs Telecomm to release the specified call from hold.
- *
- * @param callId The identifier of the call to release from hold.
- */
void unholdCall(String callId);
- /**
- * Mute the microphone.
- *
- * @param shouldMute True if the microphone should be muted.
- */
void mute(boolean shouldMute);
- /**
- * Sets the audio route (speaker, bluetooth, etc...). See {@link CallAudioState}.
- *
- * @param route The audio route to use.
- */
void setAudioRoute(int route);
+
+ void playDtmfTone(String callId, char digit);
+
+ void stopDtmfTone(String callId);
+
+ void postDialContinue(String callId);
}
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl b/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
index 4e902a2..f5847df 100644
--- a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
+++ b/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
@@ -22,64 +22,30 @@ import android.telecomm.CallInfo;
import com.android.internal.telecomm.IInCallAdapter;
/**
- * This service is implemented by any app that wishes to provide the user-interface for managing
- * phone calls. Telecomm binds to this service while there exists a live (active or incoming)
- * call, and uses it to notify the in-call app of any live and and recently disconnected calls.
- * TODO(santoscordon): Needs more/better description of lifecycle once the interface is better
- * defined.
- * TODO(santoscordon): What happens if two or more apps on a given device implement this interface?
+ * Internal remote interface for in-call services.
+ *
+ * @see android.telecomm.InCallService
+ *
* {@hide}
*/
oneway interface IInCallService {
-
- /**
- * Provides the in-call app an adapter object through which to send call-commands such as
- * answering and rejecting incoming calls, disconnecting active calls, and putting calls in
- * special states (mute, hold, etc).
- *
- * @param inCallAdapter Adapter through which an in-call app can send call-commands to Telecomm.
- */
void setInCallAdapter(in IInCallAdapter inCallAdapter);
- /**
- * Indicates to the in-call app that a new call has been created and an appropriate
- * user-interface should be built and shown to notify the user. Information about the call
- * including its current state is passed in through the callInfo object.
- *
- * @param callInfo Information about the new call.
- */
void addCall(in CallInfo callInfo);
- /**
- * Indicates to the in-call app that a call has moved to the
- * {@link android.telecomm.CallState#ACTIVE} state.
- *
- * @param callId The identifier of the call that became active.
- */
void setActive(String callId);
- /**
- * Indicates to the in-call app that a call has been moved to the
- * {@link android.telecomm.CallState#DISCONNECTED} and the user should be notified.
- *
- * @param callId The identifier of the call that was disconnected.
- * @param disconnectCause The reason for the disconnection, any of
- * {@link android.telephony.DisconnectCause}.
- */
void setDisconnected(String callId, int disconnectCause);
- /**
- * Indicates to the in-call app that a call has been moved to the
- * {@link android.telecomm.CallState#HOLD} state and the user should be notified.
- *
- * @param callId The identifier of the call that was put on hold.
- */
+ void setDialing(in String callId);
+
void setOnHold(String callId);
- /**
- * Called when the audio state changes.
- *
- * @param audioState The new {@link CallAudioState}.
- */
void onAudioStateChanged(in CallAudioState audioState);
+
+ void setRinging(String callId);
+
+ void setPostDial(String callId, String remaining);
+
+ void setPostDialWait(String callId, String remaining);
}