1 /*
2  * Copyright (C) 2014 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.internal.telecom;
18 
19 import android.app.PendingIntent;
20 import android.net.Uri;
21 import android.os.Bundle;
22 import android.telecom.ConnectionRequest;
23 import android.telecom.DisconnectCause;
24 import android.telecom.ParcelableConnection;
25 import android.telecom.ParcelableConference;
26 import android.telecom.StatusHints;
27 
28 import com.android.internal.telecom.IVideoProvider;
29 import com.android.internal.telecom.RemoteServiceCallback;
30 
31 /**
32  * Internal remote callback interface for connection services.
33  *
34  * @see android.telecom.ConnectionServiceAdapter
35  *
36  * {@hide}
37  */
38 oneway interface IConnectionServiceAdapter {
handleCreateConnectionComplete( String callId, in ConnectionRequest request, in ParcelableConnection connection)39     void handleCreateConnectionComplete(
40             String callId,
41             in ConnectionRequest request,
42             in ParcelableConnection connection);
43 
setActive(String callId)44     void setActive(String callId);
45 
setRinging(String callId)46     void setRinging(String callId);
47 
setDialing(String callId)48     void setDialing(String callId);
49 
setDisconnected(String callId, in DisconnectCause disconnectCause)50     void setDisconnected(String callId, in DisconnectCause disconnectCause);
51 
setOnHold(String callId)52     void setOnHold(String callId);
53 
setRingbackRequested(String callId, boolean ringing)54     void setRingbackRequested(String callId, boolean ringing);
55 
setConnectionCapabilities(String callId, int connectionCapabilities)56     void setConnectionCapabilities(String callId, int connectionCapabilities);
57 
setConnectionProperties(String callId, int connectionProperties)58     void setConnectionProperties(String callId, int connectionProperties);
59 
setIsConferenced(String callId, String conferenceCallId)60     void setIsConferenced(String callId, String conferenceCallId);
61 
setConferenceMergeFailed(String callId)62     void setConferenceMergeFailed(String callId);
63 
addConferenceCall(String callId, in ParcelableConference conference)64     void addConferenceCall(String callId, in ParcelableConference conference);
65 
removeCall(String callId)66     void removeCall(String callId);
67 
onPostDialWait(String callId, String remaining)68     void onPostDialWait(String callId, String remaining);
69 
onPostDialChar(String callId, char nextChar)70     void onPostDialChar(String callId, char nextChar);
71 
queryRemoteConnectionServices(RemoteServiceCallback callback)72     void queryRemoteConnectionServices(RemoteServiceCallback callback);
73 
setVideoProvider(String callId, IVideoProvider videoProvider)74     void setVideoProvider(String callId, IVideoProvider videoProvider);
75 
setVideoState(String callId, int videoState)76     void setVideoState(String callId, int videoState);
77 
setIsVoipAudioMode(String callId, boolean isVoip)78     void setIsVoipAudioMode(String callId, boolean isVoip);
79 
setStatusHints(String callId, in StatusHints statusHints)80     void setStatusHints(String callId, in StatusHints statusHints);
81 
setAddress(String callId, in Uri address, int presentation)82     void setAddress(String callId, in Uri address, int presentation);
83 
setCallerDisplayName(String callId, String callerDisplayName, int presentation)84     void setCallerDisplayName(String callId, String callerDisplayName, int presentation);
85 
setConferenceableConnections(String callId, in List<String> conferenceableCallIds)86     void setConferenceableConnections(String callId, in List<String> conferenceableCallIds);
87 
addExistingConnection(String callId, in ParcelableConnection connection)88     void addExistingConnection(String callId, in ParcelableConnection connection);
89 
putExtras(String callId, in Bundle extras)90     void putExtras(String callId, in Bundle extras);
91 
removeExtras(String callId, in List<String> keys)92     void removeExtras(String callId, in List<String> keys);
93 
onConnectionEvent(String callId, String event, in Bundle extras)94     void onConnectionEvent(String callId, String event, in Bundle extras);
95 }
96