summaryrefslogtreecommitdiff
path: root/ojluni/annotations/hiddenapi/java
AgeCommit message (Collapse)Author
2020-02-11Change j.l.r.Field to use ArtField index instead of dexFileIndexAlex Light
Using the dexFileIndex to determine the ArtField a java.lang.reflect.Field object points to requires us to use a dex-cache and to update all existing Field objects if this index changes (for example due to class redefinition). This could be rather slow. This replaces the dex-file index with the index into the declaring class's SFields/IFields arrays where the specified ArtMethod is stored. Bug: 149236640 Test: ./test.py --host Change-Id: I3598909a770aff317011091f33707773f3928c56
2019-12-11Use new UnsupportedAppUsage annotation.Artur Satayev
New annotation is tools/platform-compat/annotation/src/java/android/compat/annotation/UnsupportedAppUsage.java. Existing annotations in libcore/ and frameworks/ will be deleted after the migration: - libcore/dalvik/src/main/java/dalvik/annotation/compat/UnsupportedAppUsage.java - frameworks/base/core/java/android/annotation/UnsupportedAppUsage.java This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library. Bug: 145132366 Test: m && diff unsupportedappusage_index.csv Exempt-From-Owner-Approval: +2 by owner, by vote lost on latest patch. Change-Id: Ib5b7baa399cdc38da1d3ca622ba0ba26936b1b2d
2019-10-21Move dalvik.system.VersionCodes to dalvik.annotation.compatPaul Duffin
Avoids splitting packages that are part of java.base. Removes patch_module: "java.base" that was used to work around this issue. Bug: 143057012 Test: m checkbuild Change-Id: Iad65343fd3fde55f2d3b0e68c4bbcd51377d85d9
2019-06-18Merge "Document public alternatives to greylisted APIs" am: 9057a3dff0Andrei-Valentin Onea
am: 27695e515c Change-Id: Ica61c0a1d27966893d99de4a4963b182bfe036e3
2019-06-18Document public alternatives to greylisted APIsAndrei Onea
Add known public alternatives or recommendations for greylisted APIs in libcore. Bug: 135171386 Test: m Change-Id: I9351f2ab4c15649a5ed0e25deda1f6d9769342a4
2019-05-21Thread.uncaughtExceptionPreHandler: temporarily graylist.Tobias Thierer
Blacklisting uncaughtExceptionPreHandler in Android Pie broke a major third party app's use case. While it's too late for Pie, this CL moves the field back to the greylist for Android Q to reduce impact for that app. We still plan to blacklist this field again in a future version of Android after we've had a chance to consider whether that app's use case should be addressed by a public API. Bug: 133227292 Test: Treehugger Change-Id: I21f5bf16ed34178ae06b63e41adf84285ce8d39f
2019-02-02Merge "Remove @UnsupportedAppUsage from whitelist methods"David Brazdil
2019-02-01Remove @UnsupportedAppUsage from whitelist methodsDavid Brazdil
These were incorrectly labelled non-public. Remove their @UnsupportedAppUsage annotation. Bug: 122551864 Test: m appcompat (fails on annotation clash) Change-Id: I5149a005c3d5518fdc1dc0f7cadc597c9926d5ec
2019-01-28Add HashMap.EntryIterator.next() to greylistPaul Duffin
Bug: 122551864 Test: make checkbuild Change-Id: I25ef26f886a6ed7b5ddc0028bbb742f5b27cbdcd
2019-01-18Pass the Java caller's location to Runtime.nativeLoad.Nicolas Geoffray
Will be used to find the linker namespace to use. bug: 122874359 Test: m, gtest, run-test, CtsJdwpTests Change-Id: I65572f31c86545d027ff03626a42c7fd4dca6f64
2018-12-17Blacklist InetAddress.parseNumericAddress for QPaul Duffin
A replacement API has been provided in Q so this does not need to be accessible for apps that target Q and above. Replacement API is: android.net.InetAddresses.parseNumericAddress(String) Bug: 78686891 Test: make checkbuild - blacklist by target SDK is not supported yet. Change-Id: Iac6f5196771559de868656eee3bdc8ba233da04b
2018-12-13Remove unnecessary constants and improve JavaDocPaul Duffin
Extracted VERSION_CODES as dalvik.system.VersionCodes for general use. Bug: 119748646 Test: make checkbuild Change-Id: I67a3ec8ebaf84096ae34ba79e18b11c242ba9811
2018-11-30Blacklist primitive wrapper class value fields for Q and abovePaul Duffin
Each primitive wrapper class provides an accessor method for retrieving the value field, e.g. byteValue(), intValue() etc. so direct access to the field is not required. Bug: 118738172 Test: make checkbuild - blacklist by target SDK is not supported yet. Change-Id: I7fc2e19c7b533e892b876635dd8add3e1a811ee6
2018-11-28Add stubs for remaining libcore classes in hiddenapiPaul Duffin
Additional libcore classes and methods have been added to the hiddenapi since the last time stubs were added. This change adds stubs and annotations for them all. This was tested by making and then manually checking that the generated out/target/common/obj/PACKAGING/hiddenapi-light-greylist.txt was the same (after sorting) before and after this change. Test: see above Bug: 117818301 Change-Id: Ie860cc92a029b21d8ac0e75245a3b6d4de63199f
2018-10-31Add stubs for hiddenapiPaul Duffin
Adds stubs for ojluni classes some of whose hidden members are used by applications. Each such member is annotated with the UnsupportedAppUsage annotation. The stubs are built as part of the core-oj-hiddenapi target from which the build will extract information about the hidden class members that are used by applications. This was tested by making and then manually checking that the generated out/target/common/obj/PACKAGING/hiddenapi-light-greylist.txt was the same (after sorting) before and after this change. Test: see above Bug: 117818301 Change-Id: Icfe773e00ba1f96a379b705f26ef631ec34fee5e