1 /*
2 ** Copyright 2017, 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.telephony.mbms.vendor;
18 
19 import android.app.PendingIntent;
20 import android.net.Uri;
21 import android.telephony.mbms.DownloadRequest;
22 import android.telephony.mbms.FileInfo;
23 import android.telephony.mbms.IDownloadProgressListener;
24 import android.telephony.mbms.IDownloadStatusListener;
25 import android.telephony.mbms.IMbmsDownloadSessionCallback;
26 
27 /**
28  * @hide
29  */
30 interface IMbmsDownloadService
31 {
initialize(int subId, IMbmsDownloadSessionCallback listener)32     int initialize(int subId, IMbmsDownloadSessionCallback listener);
33 
requestUpdateFileServices(int subId, in List<String> serviceClasses)34     int requestUpdateFileServices(int subId, in List<String> serviceClasses);
35 
setTempFileRootDirectory(int subId, String rootDirectoryPath)36     int setTempFileRootDirectory(int subId, String rootDirectoryPath);
37 
addServiceAnnouncement(int subId, in byte[] contents)38     int addServiceAnnouncement(int subId, in byte[] contents);
39 
download(in DownloadRequest downloadRequest)40     int download(in DownloadRequest downloadRequest);
41 
addStatusListener(in DownloadRequest downloadRequest, IDownloadStatusListener listener)42     int addStatusListener(in DownloadRequest downloadRequest,
43         IDownloadStatusListener listener);
44 
removeStatusListener(in DownloadRequest downloadRequest, IDownloadStatusListener listener)45     int removeStatusListener(in DownloadRequest downloadRequest,
46         IDownloadStatusListener listener);
47 
addProgressListener(in DownloadRequest downloadRequest, IDownloadProgressListener listener)48     int addProgressListener(in DownloadRequest downloadRequest,
49         IDownloadProgressListener listener);
50 
removeProgressListener(in DownloadRequest downloadRequest, IDownloadProgressListener listener)51     int removeProgressListener(in DownloadRequest downloadRequest,
52         IDownloadProgressListener listener);
53 
listPendingDownloads(int subscriptionId)54     List<DownloadRequest> listPendingDownloads(int subscriptionId);
55 
cancelDownload(in DownloadRequest downloadRequest)56     int cancelDownload(in DownloadRequest downloadRequest);
57 
requestDownloadState(in DownloadRequest downloadRequest, in FileInfo fileInfo)58     int requestDownloadState(in DownloadRequest downloadRequest, in FileInfo fileInfo);
59 
resetDownloadKnowledge(in DownloadRequest downloadRequest)60     int resetDownloadKnowledge(in DownloadRequest downloadRequest);
61 
dispose(int subId)62     void dispose(int subId);
63 }
64