Integrate ImsCallSessionListener API changes
Integrates the ImsCallSessionListener API changes.
This involves:
1) Moving the ImsCallSessionListener to the
android.telephony.ims namespace.
2) Creating a compat layer between the old
IImsCallSessionListener AIDL and the new one
for vendors using the old implementation.
3) Modify ImsCallSession to only use
setListener to set ImsCallSessionListener
(other method was never used in our code).
Test: Telephony Unit Tests, Manual IMS Tests
Bug: 63987047
Merged-In: I4378c0b1d68ff4f5f21815c81af52c03a66f81c5
Change-Id: Id0cc43e9c97abb6f2776d8ad1cf599353b71e4b7
diff --git a/Android.bp b/Android.bp
index 0cd985d..afacd1c 100644
--- a/Android.bp
+++ b/Android.bp
@@ -462,7 +462,7 @@
"telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl",
"telephony/java/android/telephony/data/IDataService.aidl",
"telephony/java/android/telephony/data/IDataServiceCallback.aidl",
- "telephony/java/android/telephony/ims/internal/aidl/IImsCallSessionListener.aidl",
+ "telephony/java/android/telephony/ims/aidl/IImsCallSessionListener.aidl",
"telephony/java/android/telephony/ims/internal/aidl/IImsCapabilityCallback.aidl",
"telephony/java/android/telephony/ims/internal/aidl/IImsConfig.aidl",
"telephony/java/android/telephony/ims/internal/aidl/IImsConfigCallback.aidl",
@@ -471,7 +471,8 @@
"telephony/java/android/telephony/ims/internal/aidl/IImsRcsFeature.aidl",
"telephony/java/android/telephony/ims/internal/aidl/IImsServiceController.aidl",
"telephony/java/android/telephony/ims/internal/aidl/IImsServiceControllerListener.aidl",
- "telephony/java/android/telephony/mbms/IMbmsDownloadSessionCallback.aidl",
+ "telephony/java/android/telephony/ims/internal/aidl/IImsSmsListener.aidl",
+ "telephony/java/android/telephony/mbms/IMbmsDownloadSessionCallback.aidl",
"telephony/java/android/telephony/mbms/IMbmsStreamingSessionCallback.aidl",
"telephony/java/android/telephony/mbms/IDownloadStateCallback.aidl",
"telephony/java/android/telephony/mbms/IStreamingServiceCallback.aidl",
@@ -495,7 +496,7 @@
"telephony/java/com/android/ims/internal/IImsService.aidl",
"telephony/java/com/android/ims/internal/IImsServiceController.aidl",
"telephony/java/com/android/ims/internal/IImsServiceFeatureCallback.aidl",
- "telephony/java/com/android/ims/internal/IImsSmsListener.aidl",
+ "telephony/java/com/android/ims/internal/IImsSmsListener.aidl",
"telephony/java/com/android/ims/internal/IImsStreamMediaSession.aidl",
"telephony/java/com/android/ims/internal/IImsUt.aidl",
"telephony/java/com/android/ims/internal/IImsUtListener.aidl",
diff --git a/telephony/java/android/telephony/ims/internal/ImsCallSessionListener.java b/telephony/java/android/telephony/ims/ImsCallSessionListener.java
similarity index 87%
rename from telephony/java/android/telephony/ims/internal/ImsCallSessionListener.java
rename to telephony/java/android/telephony/ims/ImsCallSessionListener.java
index 5d16dd5..96c7af6 100644
--- a/telephony/java/android/telephony/ims/internal/ImsCallSessionListener.java
+++ b/telephony/java/android/telephony/ims/ImsCallSessionListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2017 The Android Open Source Project
+ * Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -14,16 +14,17 @@
* limitations under the License
*/
-package android.telephony.ims.internal;
+package android.telephony.ims;
import android.os.RemoteException;
-import android.telephony.ims.internal.aidl.IImsCallSessionListener;
+import android.telephony.ims.aidl.IImsCallSessionListener;
import com.android.ims.ImsCallProfile;
import com.android.ims.ImsConferenceState;
import com.android.ims.ImsReasonInfo;
import com.android.ims.ImsStreamMediaProfile;
import com.android.ims.ImsSuppServiceNotification;
+import com.android.ims.internal.IImsCallSession;
import com.android.ims.internal.ImsCallSession;
/**
@@ -138,6 +139,20 @@
}
/**
+ * Called when the session merge has been started. At this point, the {@code newSession}
+ * represents the session which has been initiated to the IMS conference server for the
+ * new merged conference.
+ *
+ * @param newSession the session object that is merged with an active & hold session
+ *
+ * @hide
+ */
+ public void callSessionMergeStarted(IImsCallSession newSession, ImsCallProfile profile)
+ throws RemoteException {
+ mListener.callSessionMergeStarted(newSession, profile);
+ }
+
+ /**
* Called when the session merge is successful and the merged session is active.
*
* @param newSession the new session object that is used for the conference
@@ -147,6 +162,17 @@
}
/**
+ * Called when the session merge is successful and the merged session is active.
+ *
+ * @param newSession the new session object that is used for the conference
+ *
+ * @hide
+ */
+ public void callSessionMergeComplete(IImsCallSession newSession) throws RemoteException {
+ mListener.callSessionMergeComplete(newSession);
+ }
+
+ /**
* Called when the session merge has failed.
*
* @param reasonInfo detailed reason of the call merge failure
@@ -191,6 +217,18 @@
}
/**
+ * Called when the session has been extended to a conference session.
+ *
+ * @param newSession the session object that is extended to the conference
+ * from the active session
+ * @hide
+ */
+ public void callSessionConferenceExtended(IImsCallSession newSession, ImsCallProfile profile)
+ throws RemoteException {
+ mListener.callSessionConferenceExtended(newSession, profile);
+ }
+
+ /**
* Called when the conference extension has failed.
*
* @param reasonInfo detailed reason of the conference extension failure
@@ -209,6 +247,16 @@
}
/**
+ * Called when the conference extension is received from the remote user.
+ *
+ * @hide
+ */
+ public void callSessionConferenceExtendReceived(IImsCallSession newSession,
+ ImsCallProfile profile) throws RemoteException {
+ mListener.callSessionConferenceExtendReceived(newSession, profile);
+ }
+
+ /**
* Called when the invitation request of the participants is delivered to the conference
* server.
*/
diff --git a/telephony/java/android/telephony/ims/internal/aidl/IImsCallSessionListener.aidl b/telephony/java/android/telephony/ims/aidl/IImsCallSessionListener.aidl
similarity index 98%
rename from telephony/java/android/telephony/ims/internal/aidl/IImsCallSessionListener.aidl
rename to telephony/java/android/telephony/ims/aidl/IImsCallSessionListener.aidl
index 2fb6744..e6a18d0 100644
--- a/telephony/java/android/telephony/ims/internal/aidl/IImsCallSessionListener.aidl
+++ b/telephony/java/android/telephony/ims/aidl/IImsCallSessionListener.aidl
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package android.telephony.ims.internal.aidl;
+package android.telephony.ims.aidl;
import com.android.ims.ImsStreamMediaProfile;
import com.android.ims.ImsCallProfile;
diff --git a/telephony/java/android/telephony/ims/compat/feature/MMTelFeature.java b/telephony/java/android/telephony/ims/compat/feature/MMTelFeature.java
new file mode 100644
index 0000000..403bb60
--- /dev/null
+++ b/telephony/java/android/telephony/ims/compat/feature/MMTelFeature.java
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2018 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License
+ */
+
+package android.telephony.ims.compat.feature;
+
+import com.android.ims.ImsCallProfile;
+import com.android.ims.internal.IImsCallSession;
+import com.android.ims.internal.IImsCallSessionListener;
+import com.android.ims.internal.ImsCallSession;
+
+/**
+ * Compatability layer for older implementations of MMTelFeature.
+ *
+ * @hide
+ */
+
+public class MMTelFeature extends android.telephony.ims.feature.MMTelFeature {
+
+ @Override
+ public final IImsCallSession createCallSession(int sessionId, ImsCallProfile profile) {
+ return createCallSession(sessionId, profile, null /*listener*/);
+ }
+
+ /**
+ * Creates an {@link ImsCallSession} with the specified call profile.
+ *
+ * @param sessionId a session id which is obtained from {@link #startSession}
+ * @param profile a call profile to make the call
+ * @param listener An implementation of IImsCallSessionListener.
+ */
+ public IImsCallSession createCallSession(int sessionId, ImsCallProfile profile,
+ IImsCallSessionListener listener) {
+ return null;
+ }
+}
diff --git a/telephony/java/android/telephony/ims/compat/stub/ImsCallSessionImplBase.java b/telephony/java/android/telephony/ims/compat/stub/ImsCallSessionImplBase.java
new file mode 100644
index 0000000..6725d29
--- /dev/null
+++ b/telephony/java/android/telephony/ims/compat/stub/ImsCallSessionImplBase.java
@@ -0,0 +1,276 @@
+/*
+ * Copyright (C) 2018 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License
+ */
+
+package android.telephony.ims.compat.stub;
+
+import android.os.RemoteException;
+import android.telephony.ims.ImsCallSessionListener;
+
+import com.android.ims.ImsCallProfile;
+import com.android.ims.ImsConferenceState;
+import com.android.ims.ImsReasonInfo;
+import com.android.ims.ImsStreamMediaProfile;
+import com.android.ims.ImsSuppServiceNotification;
+import com.android.ims.internal.IImsCallSession;
+import com.android.ims.internal.IImsCallSessionListener;
+import com.android.ims.internal.ImsCallSession;
+
+/**
+ * Compat implementation of ImsCallSessionImplBase for older implementations.
+ *
+ * DO NOT remove or change the existing APIs, only add new ones to this Base implementation or you
+ * will break other implementations of ImsCallSession maintained by other ImsServices.
+ *
+ * @hide
+ */
+
+public class ImsCallSessionImplBase extends android.telephony.ims.stub.ImsCallSessionImplBase {
+
+ @Override
+ public final void setListener(ImsCallSessionListener listener) {
+ setListener(new ImsCallSessionListenerConverter(listener));
+ }
+
+ /**
+ * Sets the listener to listen to the session events. An {@link ImsCallSession}
+ * can only hold one listener at a time. Subsequent calls to this method
+ * override the previous listener.
+ *
+ * @param listener to listen to the session events of this object
+ */
+ public void setListener(IImsCallSessionListener listener) {
+
+ }
+
+ /**
+ * There are two different ImsCallSessionListeners that need to reconciled here, we need to
+ * convert the "old" version of the com.android.ims.internal.IImsCallSessionListener to the
+ * "new" version of the Listener android.telephony.ims.ImsCallSessionListener when calling
+ * back to the framework.
+ */
+ private class ImsCallSessionListenerConverter extends IImsCallSessionListener.Stub {
+
+ private final ImsCallSessionListener mNewListener;
+
+ public ImsCallSessionListenerConverter(ImsCallSessionListener listener) {
+ mNewListener = listener;
+ }
+
+ @Override
+ public void callSessionProgressing(IImsCallSession i,
+ ImsStreamMediaProfile imsStreamMediaProfile) throws RemoteException {
+ mNewListener.callSessionProgressing(imsStreamMediaProfile);
+ }
+
+ @Override
+ public void callSessionStarted(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionInitiated(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionStartFailed(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionInitiatedFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionTerminated(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionTerminated(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionHeld(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionHeld(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionHoldFailed(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionHoldFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionHoldReceived(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionHoldReceived(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionResumed(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionResumed(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionResumeFailed(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionResumeFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionResumeReceived(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionResumeReceived(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionMergeStarted(IImsCallSession i, IImsCallSession newSession,
+ ImsCallProfile profile)
+ throws RemoteException {
+ mNewListener.callSessionMergeStarted(newSession, profile);
+ }
+
+ @Override
+ public void callSessionMergeComplete(IImsCallSession iImsCallSession)
+ throws RemoteException {
+ mNewListener.callSessionMergeComplete(iImsCallSession);
+ }
+
+ @Override
+ public void callSessionMergeFailed(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionMergeFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionUpdated(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionUpdated(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionUpdateFailed(IImsCallSession i, ImsReasonInfo imsReasonInfo)
+ throws RemoteException {
+ mNewListener.callSessionUpdateFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionUpdateReceived(IImsCallSession i, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionUpdateReceived(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionConferenceExtended(IImsCallSession i, IImsCallSession newSession,
+ ImsCallProfile imsCallProfile) throws RemoteException {
+ mNewListener.callSessionConferenceExtended(newSession, imsCallProfile);
+ }
+
+ @Override
+ public void callSessionConferenceExtendFailed(IImsCallSession i,
+ ImsReasonInfo imsReasonInfo) throws RemoteException {
+ mNewListener.callSessionConferenceExtendFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionConferenceExtendReceived(IImsCallSession i,
+ IImsCallSession newSession, ImsCallProfile imsCallProfile)
+ throws RemoteException {
+ mNewListener.callSessionConferenceExtendReceived(newSession, imsCallProfile);
+ }
+
+ @Override
+ public void callSessionInviteParticipantsRequestDelivered(IImsCallSession i)
+ throws RemoteException {
+ mNewListener.callSessionInviteParticipantsRequestDelivered();
+ }
+
+ @Override
+ public void callSessionInviteParticipantsRequestFailed(IImsCallSession i,
+ ImsReasonInfo imsReasonInfo) throws RemoteException {
+ mNewListener.callSessionInviteParticipantsRequestFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionRemoveParticipantsRequestDelivered(IImsCallSession i)
+ throws RemoteException {
+ mNewListener.callSessionRemoveParticipantsRequestDelivered();
+ }
+
+ @Override
+ public void callSessionRemoveParticipantsRequestFailed(IImsCallSession i,
+ ImsReasonInfo imsReasonInfo) throws RemoteException {
+ mNewListener.callSessionRemoveParticipantsRequestFailed(imsReasonInfo);
+ }
+
+ @Override
+ public void callSessionConferenceStateUpdated(IImsCallSession i,
+ ImsConferenceState imsConferenceState) throws RemoteException {
+ mNewListener.callSessionConferenceStateUpdated(imsConferenceState);
+ }
+
+ @Override
+ public void callSessionUssdMessageReceived(IImsCallSession i, int mode, String message)
+ throws RemoteException {
+ mNewListener.callSessionUssdMessageReceived(mode, message);
+ }
+
+ @Override
+ public void callSessionHandover(IImsCallSession i, int srcAccessTech, int targetAccessTech,
+ ImsReasonInfo reasonInfo) throws RemoteException {
+ mNewListener.callSessionHandover(srcAccessTech, targetAccessTech, reasonInfo);
+ }
+
+ @Override
+ public void callSessionHandoverFailed(IImsCallSession i, int srcAccessTech,
+ int targetAccessTech, ImsReasonInfo reasonInfo) throws RemoteException {
+ mNewListener.callSessionHandoverFailed(srcAccessTech, targetAccessTech, reasonInfo);
+ }
+
+ @Override
+ public void callSessionMayHandover(IImsCallSession i, int srcAccessTech, int targetAccessTech)
+ throws RemoteException {
+ mNewListener.callSessionMayHandover(srcAccessTech, targetAccessTech);
+ }
+
+ @Override
+ public void callSessionTtyModeReceived(IImsCallSession iImsCallSession, int mode)
+ throws RemoteException {
+ mNewListener.callSessionTtyModeReceived(mode);
+ }
+
+ @Override
+ public void callSessionMultipartyStateChanged(IImsCallSession i, boolean isMultiparty)
+ throws RemoteException {
+ mNewListener.callSessionMultipartyStateChanged(isMultiparty);
+ }
+
+ @Override
+ public void callSessionSuppServiceReceived(IImsCallSession i,
+ ImsSuppServiceNotification imsSuppServiceNotification) throws RemoteException {
+ mNewListener.callSessionSuppServiceReceived(imsSuppServiceNotification);
+ }
+
+ @Override
+ public void callSessionRttModifyRequestReceived(IImsCallSession i,
+ ImsCallProfile imsCallProfile) throws RemoteException {
+ mNewListener.callSessionRttModifyRequestReceived(imsCallProfile);
+ }
+
+ @Override
+ public void callSessionRttModifyResponseReceived(int status) throws RemoteException {
+ mNewListener.callSessionRttModifyResponseReceived(status);
+ }
+
+ @Override
+ public void callSessionRttMessageReceived(String rttMessage) throws RemoteException {
+ mNewListener.callSessionRttMessageReceived(rttMessage);
+ }
+ }
+}
diff --git a/telephony/java/android/telephony/ims/feature/MMTelFeature.java b/telephony/java/android/telephony/ims/feature/MMTelFeature.java
index 93c316f..68d63df 100644
--- a/telephony/java/android/telephony/ims/feature/MMTelFeature.java
+++ b/telephony/java/android/telephony/ims/feature/MMTelFeature.java
@@ -23,7 +23,6 @@
import com.android.ims.ImsCallProfile;
import com.android.ims.internal.IImsCallSession;
-import com.android.ims.internal.IImsCallSessionListener;
import com.android.ims.internal.IImsConfig;
import com.android.ims.internal.IImsEcbm;
import com.android.ims.internal.IImsMMTelFeature;
@@ -110,10 +109,10 @@
}
@Override
- public IImsCallSession createCallSession(int sessionId, ImsCallProfile profile,
- IImsCallSessionListener listener) throws RemoteException {
+ public IImsCallSession createCallSession(int sessionId, ImsCallProfile profile)
+ throws RemoteException {
synchronized (mLock) {
- return MMTelFeature.this.createCallSession(sessionId, profile, listener);
+ return MMTelFeature.this.createCallSession(sessionId, profile);
}
}
@@ -326,10 +325,8 @@
*
* @param sessionId a session id which is obtained from {@link #startSession}
* @param profile a call profile to make the call
- * @param listener An implementation of IImsCallSessionListener.
*/
- public IImsCallSession createCallSession(int sessionId, ImsCallProfile profile,
- IImsCallSessionListener listener) {
+ public IImsCallSession createCallSession(int sessionId, ImsCallProfile profile) {
return null;
}
diff --git a/telephony/java/android/telephony/ims/internal/aidl/IImsMmTelFeature.aidl b/telephony/java/android/telephony/ims/internal/aidl/IImsMmTelFeature.aidl
index e226ada..18afc6a 100644
--- a/telephony/java/android/telephony/ims/internal/aidl/IImsMmTelFeature.aidl
+++ b/telephony/java/android/telephony/ims/internal/aidl/IImsMmTelFeature.aidl
@@ -19,7 +19,6 @@
import android.os.Message;
import android.telephony.ims.internal.aidl.IImsMmTelListener;
import android.telephony.ims.internal.aidl.IImsCapabilityCallback;
-import android.telephony.ims.internal.aidl.IImsCallSessionListener;
import android.telephony.ims.internal.feature.CapabilityChangeRequest;
import com.android.ims.ImsCallProfile;
@@ -30,14 +29,14 @@
import com.android.ims.internal.IImsUt;
/**
- * See SmsImplBase for more information.
+ * See MmTelFeature for more information.
* {@hide}
*/
interface IImsMmTelFeature {
void setListener(IImsMmTelListener l);
int getFeatureState();
ImsCallProfile createCallProfile(int callSessionType, int callType);
- IImsCallSession createCallSession(in ImsCallProfile profile, IImsCallSessionListener listener);
+ IImsCallSession createCallSession(in ImsCallProfile profile);
IImsUt getUtInterface();
IImsEcbm getEcbmInterface();
void setUiTtyMode(int uiTtyMode, in Message onCompleteMessage);
@@ -49,4 +48,11 @@
IImsCapabilityCallback c);
oneway void queryCapabilityConfiguration(int capability, int radioTech,
IImsCapabilityCallback c);
+ // SMS APIs
+ void setSmsListener(IImsSmsListener l);
+ oneway void sendSms(in int token, int messageRef, String format, String smsc, boolean retry,
+ in byte[] pdu);
+ oneway void acknowledgeSms(int token, int messageRef, int result);
+ oneway void acknowledgeSmsReport(int token, int messageRef, int result);
+ String getSmsFormat();
}
diff --git a/telephony/java/android/telephony/ims/internal/feature/MmTelFeature.java b/telephony/java/android/telephony/ims/internal/feature/MmTelFeature.java
index 9b576c7..23e0302 100644
--- a/telephony/java/android/telephony/ims/internal/feature/MmTelFeature.java
+++ b/telephony/java/android/telephony/ims/internal/feature/MmTelFeature.java
@@ -20,11 +20,10 @@
import android.os.Message;
import android.os.RemoteException;
import android.telecom.TelecomManager;
-import android.telephony.ims.internal.ImsCallSessionListener;
-import android.telephony.ims.internal.aidl.IImsCallSessionListener;
import android.telephony.ims.internal.aidl.IImsCapabilityCallback;
import android.telephony.ims.internal.aidl.IImsMmTelFeature;
import android.telephony.ims.internal.aidl.IImsMmTelListener;
+import android.telephony.ims.internal.stub.SmsImplBase;
import android.telephony.ims.stub.ImsRegistrationImplBase;
import android.telephony.ims.stub.ImsEcbmImplBase;
import android.telephony.ims.stub.ImsMultiEndpointImplBase;
@@ -35,6 +34,7 @@
import com.android.ims.internal.IImsCallSession;
import com.android.ims.internal.IImsEcbm;
import com.android.ims.internal.IImsMultiEndpoint;
+import com.android.ims.internal.IImsSmsListener;
import com.android.ims.internal.IImsUt;
import com.android.ims.internal.ImsCallSession;
import com.android.internal.annotations.VisibleForTesting;
@@ -80,11 +80,9 @@
}
@Override
- public IImsCallSession createCallSession(ImsCallProfile profile,
- IImsCallSessionListener listener) throws RemoteException {
+ public IImsCallSession createCallSession(ImsCallProfile profile) throws RemoteException {
synchronized (mLock) {
- ImsCallSession s = MmTelFeature.this.createCallSession(profile,
- new ImsCallSessionListener(listener));
+ ImsCallSession s = MmTelFeature.this.createCallSession(profile);
return s != null ? s.getSession() : null;
}
}
@@ -143,6 +141,40 @@
IImsCapabilityCallback c) {
queryCapabilityConfigurationInternal(capability, radioTech, c);
}
+
+ @Override
+ public void setSmsListener(IImsSmsListener l) throws RemoteException {
+ MmTelFeature.this.setSmsListener(l);
+ }
+
+ @Override
+ public void sendSms(int token, int messageRef, String format, String smsc, boolean retry,
+ byte[] pdu) {
+ synchronized (mLock) {
+ MmTelFeature.this.sendSms(token, messageRef, format, smsc, retry, pdu);
+ }
+ }
+
+ @Override
+ public void acknowledgeSms(int token, int messageRef, int result) {
+ synchronized (mLock) {
+ MmTelFeature.this.acknowledgeSms(token, messageRef, result);
+ }
+ }
+
+ @Override
+ public void acknowledgeSmsReport(int token, int messageRef, int result) {
+ synchronized (mLock) {
+ MmTelFeature.this.acknowledgeSmsReport(token, messageRef, result);
+ }
+ }
+
+ @Override
+ public String getSmsFormat() {
+ synchronized (mLock) {
+ return MmTelFeature.this.getSmsFormat();
+ }
+ }
};
/**
@@ -370,10 +402,8 @@
* {@link ImsCallSession} directly.
*
* @param profile a call profile to make the call
- * @param listener An implementation of IImsCallSessionListener.
*/
- public ImsCallSession createCallSession(ImsCallProfile profile,
- ImsCallSessionListener listener) {
+ public ImsCallSession createCallSession(ImsCallProfile profile) {
// Base Implementation - Should be overridden
return null;
}
@@ -415,6 +445,40 @@
// Base Implementation - Should be overridden
}
+ public void setSmsListener(IImsSmsListener listener) {
+ getSmsImplementation().registerSmsListener(listener);
+ }
+
+ public void sendSms(int token, int messageRef, String format, String smsc, boolean isRetry,
+ byte[] pdu) {
+ getSmsImplementation().sendSms(token, messageRef, format, smsc, isRetry, pdu);
+ }
+
+ public void acknowledgeSms(int token, int messageRef,
+ @SmsImplBase.DeliverStatusResult int result) {
+ getSmsImplementation().acknowledgeSms(token, messageRef, result);
+ }
+
+ public void acknowledgeSmsReport(int token, int messageRef,
+ @SmsImplBase.StatusReportResult int result) {
+ getSmsImplementation().acknowledgeSmsReport(token, messageRef, result);
+ }
+
+ /**
+ * Must be overridden by IMS Provider to be able to support SMS over IMS. Otherwise a default
+ * non-functional implementation is returned.
+ *
+ * @return an instance of {@link SmsImplBase} which should be implemented by the IMS
+ * Provider.
+ */
+ public SmsImplBase getSmsImplementation() {
+ return new SmsImplBase();
+ }
+
+ private String getSmsFormat() {
+ return getSmsImplementation().getSmsFormat();
+ }
+
/**{@inheritDoc}*/
@Override
public void onFeatureRemoved() {
diff --git a/telephony/java/android/telephony/ims/stub/ImsCallSessionImplBase.java b/telephony/java/android/telephony/ims/stub/ImsCallSessionImplBase.java
index 80b2f78..95243fd 100644
--- a/telephony/java/android/telephony/ims/stub/ImsCallSessionImplBase.java
+++ b/telephony/java/android/telephony/ims/stub/ImsCallSessionImplBase.java
@@ -18,12 +18,13 @@
import android.os.Message;
import android.os.RemoteException;
+import android.telephony.ims.ImsCallSessionListener;
+import android.telephony.ims.aidl.IImsCallSessionListener;
import com.android.ims.ImsCallProfile;
import com.android.ims.ImsStreamMediaProfile;
import com.android.ims.internal.ImsCallSession;
import com.android.ims.internal.IImsCallSession;
-import com.android.ims.internal.IImsCallSessionListener;
import com.android.ims.internal.IImsVideoCallProvider;
/**
@@ -38,11 +39,26 @@
public class ImsCallSessionImplBase extends IImsCallSession.Stub {
+ @Override
+ public final void setListener(IImsCallSessionListener listener) throws RemoteException {
+ setListener(new ImsCallSessionListener(listener));
+ }
+
+ /**
+ * Sets the listener to listen to the session events. An {@link ImsCallSession}
+ * can only hold one listener at a time. Subsequent calls to this method
+ * override the previous listener.
+ *
+ * @param listener to listen to the session events of this object
+ */
+ public void setListener(ImsCallSessionListener listener) {
+ }
+
/**
* Closes the object. This object is not usable after being closed.
*/
@Override
- public void close() throws RemoteException {
+ public void close() {
}
@@ -52,7 +68,7 @@
* @return the call ID
*/
@Override
- public String getCallId() throws RemoteException {
+ public String getCallId() {
return null;
}
@@ -62,7 +78,7 @@
* @return the {@link ImsCallProfile} that this session is associated with
*/
@Override
- public ImsCallProfile getCallProfile() throws RemoteException {
+ public ImsCallProfile getCallProfile() {
return null;
}
@@ -72,7 +88,7 @@
* @return the local {@link ImsCallProfile} that this session is associated with
*/
@Override
- public ImsCallProfile getLocalCallProfile() throws RemoteException {
+ public ImsCallProfile getLocalCallProfile() {
return null;
}
@@ -82,7 +98,7 @@
* @return the remote {@link ImsCallProfile} that this session is associated with
*/
@Override
- public ImsCallProfile getRemoteCallProfile() throws RemoteException {
+ public ImsCallProfile getRemoteCallProfile() {
return null;
}
@@ -92,7 +108,7 @@
* @return the string value associated with the specified property
*/
@Override
- public String getProperty(String name) throws RemoteException {
+ public String getProperty(String name) {
return null;
}
@@ -103,7 +119,7 @@
* @return the session state
*/
@Override
- public int getState() throws RemoteException {
+ public int getState() {
return ImsCallSession.State.INVALID;
}
@@ -113,28 +129,17 @@
* @return true if the session is in call, false otherwise
*/
@Override
- public boolean isInCall() throws RemoteException {
+ public boolean isInCall() {
return false;
}
/**
- * Sets the listener to listen to the session events. An {@link ImsCallSession}
- * can only hold one listener at a time. Subsequent calls to this method
- * override the previous listener.
- *
- * @param listener to listen to the session events of this object
- */
- @Override
- public void setListener(IImsCallSessionListener listener) throws RemoteException {
- }
-
- /**
* Mutes or unmutes the mic for the active call.
*
* @param muted true if the call is muted, false otherwise
*/
@Override
- public void setMute(boolean muted) throws RemoteException {
+ public void setMute(boolean muted) {
}
/**
@@ -150,7 +155,7 @@
* {@link ImsCallSession.Listener#callSessionStartFailed}
*/
@Override
- public void start(String callee, ImsCallProfile profile) throws RemoteException {
+ public void start(String callee, ImsCallProfile profile) {
}
/**
@@ -166,8 +171,7 @@
* {@link ImsCallSession.Listener#callSessionStartFailed}
*/
@Override
- public void startConference(String[] participants, ImsCallProfile profile)
- throws RemoteException {
+ public void startConference(String[] participants, ImsCallProfile profile) {
}
/**
@@ -178,7 +182,7 @@
* @see {@link ImsCallSession.Listener#callSessionStarted}
*/
@Override
- public void accept(int callType, ImsStreamMediaProfile profile) throws RemoteException {
+ public void accept(int callType, ImsStreamMediaProfile profile) {
}
/**
@@ -189,7 +193,7 @@
* {@link ImsCallSession.Listener#callSessionStartFailed}
*/
@Override
- public void reject(int reason) throws RemoteException {
+ public void reject(int reason) {
}
/**
@@ -201,7 +205,7 @@
* @see {@link ImsCallSession.Listener#callSessionTerminated}
*/
@Override
- public void terminate(int reason) throws RemoteException {
+ public void terminate(int reason) {
}
/**
@@ -213,7 +217,7 @@
* {@link ImsCallSession.Listener#callSessionHoldFailed}
*/
@Override
- public void hold(ImsStreamMediaProfile profile) throws RemoteException {
+ public void hold(ImsStreamMediaProfile profile) {
}
/**
@@ -225,7 +229,7 @@
* {@link ImsCallSession.Listener#callSessionResumeFailed}
*/
@Override
- public void resume(ImsStreamMediaProfile profile) throws RemoteException {
+ public void resume(ImsStreamMediaProfile profile) {
}
/**
@@ -240,7 +244,7 @@
* {@link ImsCallSession.Listener#callSessionMergeFailed}
*/
@Override
- public void merge() throws RemoteException {
+ public void merge() {
}
/**
@@ -252,7 +256,7 @@
* {@link ImsCallSession.Listener#callSessionUpdateFailed}
*/
@Override
- public void update(int callType, ImsStreamMediaProfile profile) throws RemoteException {
+ public void update(int callType, ImsStreamMediaProfile profile) {
}
/**
@@ -264,7 +268,7 @@
* {@link ImsCallSession.Listener#callSessionConferenceExtendFailed}
*/
@Override
- public void extendToConference(String[] participants) throws RemoteException {
+ public void extendToConference(String[] participants) {
}
/**
@@ -286,7 +290,7 @@
* {@link ImsCallSession.Listener#callSessionRemoveParticipantsRequestFailed}
*/
@Override
- public void removeParticipants(String[] participants) throws RemoteException {
+ public void removeParticipants(String[] participants) {
}
/**
@@ -297,7 +301,7 @@
* @param c the DTMF to send. '0' ~ '9', 'A' ~ 'D', '*', '#' are valid inputs.
*/
@Override
- public void sendDtmf(char c, Message result) throws RemoteException {
+ public void sendDtmf(char c, Message result) {
}
/**
@@ -308,14 +312,14 @@
* @param c the DTMF to send. '0' ~ '9', 'A' ~ 'D', '*', '#' are valid inputs.
*/
@Override
- public void startDtmf(char c) throws RemoteException {
+ public void startDtmf(char c) {
}
/**
* Stop a DTMF code.
*/
@Override
- public void stopDtmf() throws RemoteException {
+ public void stopDtmf() {
}
/**
@@ -324,7 +328,7 @@
* @param ussdMessage USSD message to send
*/
@Override
- public void sendUssd(String ussdMessage) throws RemoteException {
+ public void sendUssd(String ussdMessage) {
}
/**
@@ -333,7 +337,7 @@
* intermediates between the propriety implementation and Telecomm/InCall.
*/
@Override
- public IImsVideoCallProvider getVideoCallProvider() throws RemoteException {
+ public IImsVideoCallProvider getVideoCallProvider() {
return null;
}
@@ -342,7 +346,7 @@
* @return {@code True} if the session is multiparty.
*/
@Override
- public boolean isMultiparty() throws RemoteException {
+ public boolean isMultiparty() {
return false;
}
diff --git a/telephony/java/android/telephony/ims/stub/ImsCallSessionListenerImplBase.java b/telephony/java/android/telephony/ims/stub/ImsCallSessionListenerImplBase.java
deleted file mode 100644
index 6c18935..0000000
--- a/telephony/java/android/telephony/ims/stub/ImsCallSessionListenerImplBase.java
+++ /dev/null
@@ -1,298 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License
- */
-
-package android.telephony.ims.stub;
-
-import com.android.ims.ImsCallProfile;
-import com.android.ims.ImsConferenceState;
-import com.android.ims.ImsReasonInfo;
-import com.android.ims.ImsStreamMediaProfile;
-import com.android.ims.ImsSuppServiceNotification;
-import com.android.ims.internal.IImsCallSession;
-import com.android.ims.internal.IImsCallSessionListener;
-
-/**
- * Base implementation of ImsCallSessionListenerBase, which implements stub versions of the methods
- * in the IImsCallSessionListener AIDL. Override the methods that your implementation of
- * ImsCallSessionListener supports.
- *
- * DO NOT remove or change the existing APIs, only add new ones to this Base implementation or you
- * will break other implementations of ImsCallSessionListener maintained by other ImsServices.
- *
- * @hide
- */
-public class ImsCallSessionListenerImplBase extends IImsCallSessionListener.Stub {
- /**
- * Notifies the result of the basic session operation (setup / terminate).
- */
- @Override
- public void callSessionProgressing(IImsCallSession session, ImsStreamMediaProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionStarted(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionStartFailed(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionTerminated(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- /**
- * Notifies the result of the call hold/resume operation.
- */
- @Override
- public void callSessionHeld(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionHoldFailed(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionHoldReceived(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionResumed(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionResumeFailed(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionResumeReceived(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- /**
- * Notifies the result of call merge operation.
- */
- @Override
- public void callSessionMergeStarted(IImsCallSession session, IImsCallSession newSession,
- ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionMergeComplete(IImsCallSession session) {
- // no-op
- }
-
- @Override
- public void callSessionMergeFailed(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- /**
- * Notifies the result of call upgrade / downgrade or any other call
- * updates.
- */
- @Override
- public void callSessionUpdated(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionUpdateFailed(IImsCallSession session, ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionUpdateReceived(IImsCallSession session, ImsCallProfile profile) {
- // no-op
- }
-
- /**
- * Notifies the result of conference extension.
- */
- @Override
- public void callSessionConferenceExtended(IImsCallSession session, IImsCallSession newSession,
- ImsCallProfile profile) {
- // no-op
- }
-
- @Override
- public void callSessionConferenceExtendFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionConferenceExtendReceived(IImsCallSession session,
- IImsCallSession newSession,
- ImsCallProfile profile) {
- // no-op
- }
-
- /**
- * Notifies the result of the participant invitation / removal to/from the
- * conference session.
- */
- @Override
- public void callSessionInviteParticipantsRequestDelivered(IImsCallSession session) {
- // no-op
- }
-
- @Override
- public void callSessionInviteParticipantsRequestFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionRemoveParticipantsRequestDelivered(IImsCallSession session) {
- // no-op
- }
-
- @Override
- public void callSessionRemoveParticipantsRequestFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- /**
- * Notifies the changes of the conference info. the conference session.
- */
- @Override
- public void callSessionConferenceStateUpdated(IImsCallSession session,
- ImsConferenceState state) {
- // no-op
- }
-
- /**
- * Notifies the incoming USSD message.
- */
- @Override
- public void callSessionUssdMessageReceived(IImsCallSession session, int mode,
- String ussdMessage) {
- // no-op
- }
-
- /**
- * Notifies of a case where a {@link com.android.ims.internal.ImsCallSession} may potentially
- * handover from one radio technology to another.
- * @param session
- * @param srcAccessTech The source radio access technology; one of the access technology
- * constants defined in {@link android.telephony.ServiceState}. For
- * example {@link android.telephony.ServiceState#RIL_RADIO_TECHNOLOGY_LTE}.
- * @param targetAccessTech The target radio access technology; one of the access technology
- * constants defined in {@link android.telephony.ServiceState}. For
- * example {@link android.telephony.ServiceState#RIL_RADIO_TECHNOLOGY_LTE}.
- */
- @Override
- public void callSessionMayHandover(IImsCallSession session, int srcAccessTech,
- int targetAccessTech) {
- // no-op
- }
-
- /**
- * Notifies of handover information for this call
- */
- @Override
- public void callSessionHandover(IImsCallSession session, int srcAccessTech,
- int targetAccessTech,
- ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- @Override
- public void callSessionHandoverFailed(IImsCallSession session, int srcAccessTech,
- int targetAccessTech,
- ImsReasonInfo reasonInfo) {
- // no-op
- }
-
- /**
- * Notifies the TTY mode change by remote party.
- *
- * @param mode one of the following: -
- * {@link com.android.internal.telephony.Phone#TTY_MODE_OFF} -
- * {@link com.android.internal.telephony.Phone#TTY_MODE_FULL} -
- * {@link com.android.internal.telephony.Phone#TTY_MODE_HCO} -
- * {@link com.android.internal.telephony.Phone#TTY_MODE_VCO}
- */
- @Override
- public void callSessionTtyModeReceived(IImsCallSession session, int mode) {
- // no-op
- }
-
- /**
- * Notifies of a change to the multiparty state for this
- * {@code ImsCallSession}.
- *
- * @param session The call session.
- * @param isMultiParty {@code true} if the session became multiparty,
- * {@code false} otherwise.
- */
- @Override
- public void callSessionMultipartyStateChanged(IImsCallSession session, boolean isMultiParty) {
- // no-op
- }
-
- /**
- * Notifies the supplementary service information for the current session.
- */
- @Override
- public void callSessionSuppServiceReceived(IImsCallSession session,
- ImsSuppServiceNotification suppSrvNotification) {
- // no-op
- }
-
- /**
- * Received RTT modify request from Remote Party
- * @param session The call session.
- * @param callProfile ImsCallProfile with updated attribute
- */
- @Override
- public void callSessionRttModifyRequestReceived(IImsCallSession session,
- ImsCallProfile callProfile) {
- // no-op
- }
-
- /**
- * Received response for RTT modify request
- * @param status true : Accepted the request
- * false : Declined the request
- */
- @Override
- public void callSessionRttModifyResponseReceived(int status) {
- // no -op
- }
-
- /**
- * Device received RTT message from Remote UE
- * @param rttMessage RTT message received
- */
- @Override
- public void callSessionRttMessageReceived(String rttMessage) {
- // no-op
- }
-}
-
diff --git a/telephony/java/com/android/ims/internal/IImsCallSession.aidl b/telephony/java/com/android/ims/internal/IImsCallSession.aidl
index c6fc5e5..b477dea 100644
--- a/telephony/java/com/android/ims/internal/IImsCallSession.aidl
+++ b/telephony/java/com/android/ims/internal/IImsCallSession.aidl
@@ -17,9 +17,10 @@
package com.android.ims.internal;
import android.os.Message;
+import android.telephony.ims.aidl.IImsCallSessionListener;
+
import com.android.ims.ImsCallProfile;
import com.android.ims.ImsStreamMediaProfile;
-import com.android.ims.internal.IImsCallSessionListener;
import com.android.ims.internal.IImsVideoCallProvider;
/**
diff --git a/telephony/java/com/android/ims/internal/IImsMMTelFeature.aidl b/telephony/java/com/android/ims/internal/IImsMMTelFeature.aidl
index 10c7f3e..290a682 100644
--- a/telephony/java/com/android/ims/internal/IImsMMTelFeature.aidl
+++ b/telephony/java/com/android/ims/internal/IImsMMTelFeature.aidl
@@ -20,7 +20,6 @@
import com.android.ims.ImsCallProfile;
import com.android.ims.internal.IImsCallSession;
-import com.android.ims.internal.IImsCallSessionListener;
import com.android.ims.internal.IImsConfig;
import com.android.ims.internal.IImsEcbm;
import com.android.ims.internal.IImsMultiEndpoint;
@@ -44,8 +43,7 @@
void addRegistrationListener(in IImsRegistrationListener listener);
void removeRegistrationListener(in IImsRegistrationListener listener);
ImsCallProfile createCallProfile(int sessionId, int callSessionType, int callType);
- IImsCallSession createCallSession(int sessionId, in ImsCallProfile profile,
- IImsCallSessionListener listener);
+ IImsCallSession createCallSession(int sessionId, in ImsCallProfile profile);
IImsCallSession getPendingCallSession(int sessionId, String callId);
IImsUt getUtInterface();
IImsConfig getConfigInterface();
diff --git a/telephony/java/com/android/ims/internal/ImsCallSession.java b/telephony/java/com/android/ims/internal/ImsCallSession.java
index 1736b80..e914f48 100644
--- a/telephony/java/com/android/ims/internal/ImsCallSession.java
+++ b/telephony/java/com/android/ims/internal/ImsCallSession.java
@@ -18,10 +18,10 @@
import android.os.Message;
import android.os.RemoteException;
+import android.telephony.ims.aidl.IImsCallSessionListener;
import java.util.Objects;
-import android.telephony.ims.stub.ImsCallSessionListenerImplBase;
import android.util.Log;
import com.android.ims.ImsCallProfile;
import com.android.ims.ImsConferenceState;
@@ -987,7 +987,6 @@
* Sends Rtt Message
*
* @param rttMessage rtt text to be sent
- * @throws ImsException if call is absent
*/
public void sendRttMessage(String rttMessage) {
if (mClosed) {
@@ -1004,7 +1003,6 @@
* Sends RTT Upgrade request
*
* @param to : expected profile
- * @throws CallStateException
*/
public void sendRttModifyRequest(ImsCallProfile to) {
if (mClosed) {
@@ -1021,7 +1019,6 @@
* Sends RTT Upgrade response
*
* @param response : response for upgrade
- * @throws CallStateException
*/
public void sendRttModifyResponse(boolean response) {
if (mClosed) {
@@ -1040,37 +1037,33 @@
* the application is notified by having one of the methods called on
* the {@link IImsCallSessionListener}.
*/
- private class IImsCallSessionListenerProxy extends ImsCallSessionListenerImplBase {
+ private class IImsCallSessionListenerProxy extends IImsCallSessionListener.Stub {
/**
* Notifies the result of the basic session operation (setup / terminate).
*/
@Override
- public void callSessionProgressing(IImsCallSession session,
- ImsStreamMediaProfile profile) {
+ public void callSessionProgressing(ImsStreamMediaProfile profile) {
if (mListener != null) {
mListener.callSessionProgressing(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionStarted(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionInitiated(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionStarted(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionStartFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionInitiatedFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionStartFailed(ImsCallSession.this, reasonInfo);
}
}
@Override
- public void callSessionTerminated(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionTerminated(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionTerminated(ImsCallSession.this, reasonInfo);
}
@@ -1080,48 +1073,42 @@
* Notifies the result of the call hold/resume operation.
*/
@Override
- public void callSessionHeld(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionHeld(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionHeld(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionHoldFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionHoldFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionHoldFailed(ImsCallSession.this, reasonInfo);
}
}
@Override
- public void callSessionHoldReceived(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionHoldReceived(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionHoldReceived(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionResumed(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionResumed(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionResumed(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionResumeFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionResumeFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionResumeFailed(ImsCallSession.this, reasonInfo);
}
}
@Override
- public void callSessionResumeReceived(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionResumeReceived(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionResumeReceived(ImsCallSession.this, profile);
}
@@ -1130,13 +1117,11 @@
/**
* Notifies the start of a call merge operation.
*
- * @param session The call session.
* @param newSession The merged call session.
* @param profile The call profile.
*/
@Override
- public void callSessionMergeStarted(IImsCallSession session,
- IImsCallSession newSession, ImsCallProfile profile) {
+ public void callSessionMergeStarted(IImsCallSession newSession, ImsCallProfile profile) {
// This callback can be used for future use to add additional
// functionality that may be needed between conference start and complete
Log.d(TAG, "callSessionMergeStarted");
@@ -1173,12 +1158,10 @@
/**
* Notifies of a failure to perform a call merge operation.
*
- * @param session The call session.
* @param reasonInfo The merge failure reason.
*/
@Override
- public void callSessionMergeFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionMergeFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionMergeFailed(ImsCallSession.this, reasonInfo);
}
@@ -1188,24 +1171,21 @@
* Notifies the result of call upgrade / downgrade or any other call updates.
*/
@Override
- public void callSessionUpdated(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionUpdated(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionUpdated(ImsCallSession.this, profile);
}
}
@Override
- public void callSessionUpdateFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionUpdateFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionUpdateFailed(ImsCallSession.this, reasonInfo);
}
}
@Override
- public void callSessionUpdateReceived(IImsCallSession session,
- ImsCallProfile profile) {
+ public void callSessionUpdateReceived(ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionUpdateReceived(ImsCallSession.this, profile);
}
@@ -1215,8 +1195,8 @@
* Notifies the result of conference extension.
*/
@Override
- public void callSessionConferenceExtended(IImsCallSession session,
- IImsCallSession newSession, ImsCallProfile profile) {
+ public void callSessionConferenceExtended(IImsCallSession newSession,
+ ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionConferenceExtended(ImsCallSession.this,
new ImsCallSession(newSession), profile);
@@ -1224,16 +1204,15 @@
}
@Override
- public void callSessionConferenceExtendFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionConferenceExtendFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionConferenceExtendFailed(ImsCallSession.this, reasonInfo);
}
}
@Override
- public void callSessionConferenceExtendReceived(IImsCallSession session,
- IImsCallSession newSession, ImsCallProfile profile) {
+ public void callSessionConferenceExtendReceived(IImsCallSession newSession,
+ ImsCallProfile profile) {
if (mListener != null) {
mListener.callSessionConferenceExtendReceived(ImsCallSession.this,
new ImsCallSession(newSession), profile);
@@ -1245,15 +1224,14 @@
* the conference session.
*/
@Override
- public void callSessionInviteParticipantsRequestDelivered(IImsCallSession session) {
+ public void callSessionInviteParticipantsRequestDelivered() {
if (mListener != null) {
mListener.callSessionInviteParticipantsRequestDelivered(ImsCallSession.this);
}
}
@Override
- public void callSessionInviteParticipantsRequestFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionInviteParticipantsRequestFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionInviteParticipantsRequestFailed(ImsCallSession.this,
reasonInfo);
@@ -1261,15 +1239,14 @@
}
@Override
- public void callSessionRemoveParticipantsRequestDelivered(IImsCallSession session) {
+ public void callSessionRemoveParticipantsRequestDelivered() {
if (mListener != null) {
mListener.callSessionRemoveParticipantsRequestDelivered(ImsCallSession.this);
}
}
@Override
- public void callSessionRemoveParticipantsRequestFailed(IImsCallSession session,
- ImsReasonInfo reasonInfo) {
+ public void callSessionRemoveParticipantsRequestFailed(ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionRemoveParticipantsRequestFailed(ImsCallSession.this,
reasonInfo);
@@ -1280,8 +1257,7 @@
* Notifies the changes of the conference info. in the conference session.
*/
@Override
- public void callSessionConferenceStateUpdated(IImsCallSession session,
- ImsConferenceState state) {
+ public void callSessionConferenceStateUpdated(ImsConferenceState state) {
if (mListener != null) {
mListener.callSessionConferenceStateUpdated(ImsCallSession.this, state);
}
@@ -1291,8 +1267,7 @@
* Notifies the incoming USSD message.
*/
@Override
- public void callSessionUssdMessageReceived(IImsCallSession session,
- int mode, String ussdMessage) {
+ public void callSessionUssdMessageReceived(int mode, String ussdMessage) {
if (mListener != null) {
mListener.callSessionUssdMessageReceived(ImsCallSession.this, mode, ussdMessage);
}
@@ -1301,7 +1276,6 @@
/**
* Notifies of a case where a {@link com.android.ims.internal.ImsCallSession} may
* potentially handover from one radio technology to another.
- * @param session
* @param srcAccessTech The source radio access technology; one of the access technology
* constants defined in {@link android.telephony.ServiceState}. For
* example
@@ -1312,8 +1286,7 @@
* {@link android.telephony.ServiceState#RIL_RADIO_TECHNOLOGY_LTE}.
*/
@Override
- public void callSessionMayHandover(IImsCallSession session,
- int srcAccessTech, int targetAccessTech) {
+ public void callSessionMayHandover(int srcAccessTech, int targetAccessTech) {
if (mListener != null) {
mListener.callSessionMayHandover(ImsCallSession.this, srcAccessTech,
targetAccessTech);
@@ -1324,9 +1297,8 @@
* Notifies of handover information for this call
*/
@Override
- public void callSessionHandover(IImsCallSession session,
- int srcAccessTech, int targetAccessTech,
- ImsReasonInfo reasonInfo) {
+ public void callSessionHandover(int srcAccessTech, int targetAccessTech,
+ ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionHandover(ImsCallSession.this, srcAccessTech,
targetAccessTech, reasonInfo);
@@ -1337,9 +1309,8 @@
* Notifies of handover failure info for this call
*/
@Override
- public void callSessionHandoverFailed(IImsCallSession session,
- int srcAccessTech, int targetAccessTech,
- ImsReasonInfo reasonInfo) {
+ public void callSessionHandoverFailed(int srcAccessTech, int targetAccessTech,
+ ImsReasonInfo reasonInfo) {
if (mListener != null) {
mListener.callSessionHandoverFailed(ImsCallSession.this, srcAccessTech,
targetAccessTech, reasonInfo);
@@ -1350,8 +1321,7 @@
* Notifies the TTY mode received from remote party.
*/
@Override
- public void callSessionTtyModeReceived(IImsCallSession session,
- int mode) {
+ public void callSessionTtyModeReceived(int mode) {
if (mListener != null) {
mListener.callSessionTtyModeReceived(ImsCallSession.this, mode);
}
@@ -1360,21 +1330,17 @@
/**
* Notifies of a change to the multiparty state for this {@code ImsCallSession}.
*
- * @param session The call session.
* @param isMultiParty {@code true} if the session became multiparty, {@code false}
* otherwise.
*/
- public void callSessionMultipartyStateChanged(IImsCallSession session,
- boolean isMultiParty) {
-
+ public void callSessionMultipartyStateChanged(boolean isMultiParty) {
if (mListener != null) {
mListener.callSessionMultipartyStateChanged(ImsCallSession.this, isMultiParty);
}
}
@Override
- public void callSessionSuppServiceReceived(IImsCallSession session,
- ImsSuppServiceNotification suppServiceInfo ) {
+ public void callSessionSuppServiceReceived(ImsSuppServiceNotification suppServiceInfo ) {
if (mListener != null) {
mListener.callSessionSuppServiceReceived(ImsCallSession.this, suppServiceInfo);
}
@@ -1384,8 +1350,7 @@
* Received RTT modify request from remote party
*/
@Override
- public void callSessionRttModifyRequestReceived(IImsCallSession session,
- ImsCallProfile callProfile) {
+ public void callSessionRttModifyRequestReceived(ImsCallProfile callProfile) {
if (mListener != null) {
mListener.callSessionRttModifyRequestReceived(ImsCallSession.this, callProfile);
}