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
17package com.android.internal.telecom;
18
19import android.app.PendingIntent;
20import android.net.Uri;
21import android.os.Bundle;
22import android.telecom.ConnectionRequest;
23import android.telecom.DisconnectCause;
24import android.telecom.ParcelableConnection;
25import android.telecom.ParcelableConference;
26import android.telecom.StatusHints;
27
28import com.android.internal.telecom.IVideoProvider;
29import 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 */
38oneway interface IConnectionServiceAdapter {
39    void handleCreateConnectionComplete(
40            String callId,
41            in ConnectionRequest request,
42            in ParcelableConnection connection);
43
44    void setActive(String callId);
45
46    void setRinging(String callId);
47
48    void setDialing(String callId);
49
50    void setPulling(String callId);
51
52    void setDisconnected(String callId, in DisconnectCause disconnectCause);
53
54    void setOnHold(String callId);
55
56    void setRingbackRequested(String callId, boolean ringing);
57
58    void setConnectionCapabilities(String callId, int connectionCapabilities);
59
60    void setConnectionProperties(String callId, int connectionProperties);
61
62    void setIsConferenced(String callId, String conferenceCallId);
63
64    void setConferenceMergeFailed(String callId);
65
66    void addConferenceCall(String callId, in ParcelableConference conference);
67
68    void removeCall(String callId);
69
70    void onPostDialWait(String callId, String remaining);
71
72    void onPostDialChar(String callId, char nextChar);
73
74    void queryRemoteConnectionServices(RemoteServiceCallback callback);
75
76    void setVideoProvider(String callId, IVideoProvider videoProvider);
77
78    void setVideoState(String callId, int videoState);
79
80    void setIsVoipAudioMode(String callId, boolean isVoip);
81
82    void setStatusHints(String callId, in StatusHints statusHints);
83
84    void setAddress(String callId, in Uri address, int presentation);
85
86    void setCallerDisplayName(String callId, String callerDisplayName, int presentation);
87
88    void setConferenceableConnections(String callId, in List<String> conferenceableCallIds);
89
90    void addExistingConnection(String callId, in ParcelableConnection connection);
91
92    void putExtras(String callId, in Bundle extras);
93
94    void removeExtras(String callId, in List<String> keys);
95
96    void onConnectionEvent(String callId, String event, in Bundle extras);
97}
98