1// Copyright (C) 2018 The Android Open Source Project
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.
14
15// Generates stub source files for the intra-core API of the ART module.
16// i.e. every class/member that is either in the public API or annotated with
17// @IntraCoreApi.
18//
19// The API specification .txt files managed by this only contain the additional
20// classes/members that are in the intra-core API but which are not in the public
21// API.
22droidstubs {
23    name: "art-module-intra-core-api-stubs-source",
24    srcs: [
25        ":art_module_api_files",
26    ],
27    sdk_version: "none",
28    system_modules: "none",
29
30    installable: false,
31    args: "--hide-annotation libcore.api.Hide " +
32        "--show-single-annotation libcore.api.IntraCoreApi " +
33        "--skip-annotation-instance-methods=false ",
34    merge_inclusion_annotations_dirs: ["ojluni-annotated-mmodule-stubs"],
35
36    api_filename: "api.txt",
37    removed_api_filename: "removed.txt",
38    previous_api: "previous.txt",
39    check_api: {
40        current: {
41            api_file: "api/intra/current-api.txt",
42            removed_api_file: "api/intra/current-removed.txt",
43        },
44        last_released: {
45            api_file: "api/intra/last-api.txt",
46            removed_api_file: "api/intra/last-removed.txt",
47        },
48    },
49}
50
51// A library containing the intra-core API stubs of the ART module.
52//
53// Intra-core APIs are only intended for the use of other core library modules.
54java_library {
55    name: "art.module.intra.core.api.stubs",
56    visibility: [
57        "//libcore/mmodules/core_platform_api",
58    ],
59    srcs: [
60        ":art-module-intra-core-api-stubs-source",
61        ":openjdk_lambda_stub_files",
62        ":openjdk_generated_annotation_stub_files",
63    ],
64
65    sdk_version: "none",
66    system_modules: "none",
67    patch_module: "java.base",
68}
69
70// Used when compiling against art.module.intra.core.api.stubs.
71java_system_modules {
72    name: "art-module-intra-core-api-stubs-system-modules",
73    visibility: [
74        "//art/build/sdk",
75        "//external/bouncycastle",
76        "//external/conscrypt",
77        "//external/icu/android_icu4j",
78    ],
79    libs: ["art.module.intra.core.api.stubs"],
80}
81