Debian Codegraph @

core/java/android/app/people/IPeopleManager.aidl

raw
1 /*
2 * Copyright (C) 2020 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 android.app.people;
18
19 import android.app.people.ConversationStatus;
20 import android.app.people.ConversationChannel;
21 import android.app.people.IConversationListener;
22 import android.content.pm.ParceledListSlice;
23 import android.net.Uri;
24 import android.os.IBinder;
25
26 /**
27 * System private API for talking with the people service.
28 * {@hide}
29 */
30 interface IPeopleManager {
31
32 /**
33 * Returns the specified conversation from the conversations list. If the conversation can't be
34 * found, returns null.
35 */
36 ConversationChannel getConversation(in String packageName, int userId, in String shortcutId);
37
38 /**
39 * Returns the recent conversations. The conversations that have customized notification
40 * settings are excluded from the returned list.
41 */
42 ParceledListSlice getRecentConversations();
43
44 /**
45 * Removes the specified conversation from the recent conversations list and uncaches the
46 * shortcut associated with the conversation.
47 */
48 void removeRecentConversation(in String packageName, int userId, in String shortcutId);
49
50 /** Removes all the recent conversations and uncaches their cached shortcuts. */
51 void removeAllRecentConversations();
52
53 /** Returns whether the shortcutId is backed by a Conversation in People Service. */
54 boolean isConversation(in String packageName, int userId, in String shortcutId);
55
56 /**
57 * Returns the last interaction with the specified conversation. If the
58 * conversation can't be found or no interactions have been recorded, returns 0L.
59 */
60 long getLastInteraction(in String packageName, int userId, in String shortcutId);
61
62 void addOrUpdateStatus(in String packageName, int userId, in String conversationId, in ConversationStatus status);
63 void clearStatus(in String packageName, int userId, in String conversationId, in String statusId);
64 void clearStatuses(in String packageName, int userId, in String conversationId);
65 ParceledListSlice getStatuses(in String packageName, int userId, in String conversationId);
66 void registerConversationListener(in String packageName, int userId, in String shortcutId, in IConversationListener callback);
67 void unregisterConversationListener(in IConversationListener callback);
68 }