• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2022 Google LLC
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#      http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14load("@build_bazel_rules_android//android:rules.bzl", "android_library")
15
16# MDD Lite visibility is restricted to the following set of packages. Any
17# new clients must be added to this list in order to grant build visibility.
18package(
19    default_applicable_licenses = ["//:license"],
20    default_visibility = [
21        "//visibility:public",
22    ],
23    licenses = ["notice"],
24)
25
26android_library(
27    name = "lite",
28    srcs = glob(
29        ["*.java"],
30        exclude = [
31            "DownloadListener.java",
32            "DownloadProgressMonitor.java",
33            "SingleFileDownloadProgressMonitor.java",
34        ],
35    ),
36    deps = [
37        ":DownloadListener",
38        ":DownloadProgressMonitor",
39        "//java/com/google/android/libraries/mobiledatadownload:DownloadException",
40        "//java/com/google/android/libraries/mobiledatadownload/downloader:FileDownloader",
41        "//java/com/google/android/libraries/mobiledatadownload/foreground:ForegroundDownloadKey",
42        "//java/com/google/android/libraries/mobiledatadownload/foreground:NotificationUtil",
43        "//java/com/google/android/libraries/mobiledatadownload/internal/logging:LogUtil",
44        "//java/com/google/android/libraries/mobiledatadownload/internal/util:DownloadFutureMap",
45        "//java/com/google/android/libraries/mobiledatadownload/tracing",
46        "//java/com/google/android/libraries/mobiledatadownload/tracing:concurrent",
47        "@androidx_annotation_annotation",
48        "@androidx_core_core",
49        "@com_google_auto_value",
50        "@com_google_errorprone_error_prone_annotations",
51        "@com_google_guava_guava",
52        "@org_checkerframework_qual",
53    ],
54)
55
56android_library(
57    name = "DownloadListener",
58    srcs = ["DownloadListener.java"],
59    deps = [
60        "//proto:client_config_java_proto_lite",
61        "@com_google_guava_guava",
62    ],
63)
64
65android_library(
66    name = "DownloadProgressMonitor",
67    srcs = [
68        "DownloadProgressMonitor.java",
69        "SingleFileDownloadProgressMonitor.java",
70    ],
71    deps = [
72        ":DownloadListener",
73        "//java/com/google/android/libraries/mobiledatadownload:TimeSource",
74        "//java/com/google/android/libraries/mobiledatadownload/file/spi",
75        "//java/com/google/android/libraries/mobiledatadownload/internal:AndroidTimeSource",
76        "//java/com/google/android/libraries/mobiledatadownload/internal/logging:LogUtil",
77        "@androidx_annotation_annotation",
78        "@com_google_code_findbugs_jsr305",
79        "@com_google_errorprone_error_prone_annotations",
80        "@com_google_guava_guava",
81    ],
82)
83