File tree 2 files changed +25
-4
lines changed
main/resources/de/thetaphi/forbiddenapis/signatures
tools/java/de/thetaphi/forbiddenapis
2 files changed +25
-4
lines changed Original file line number Diff line number Diff line change 1
- # This file contains API signatures that are marked as internal in Java.
2
- # It is provided here for reference, but can easily regenerated by executing from the source folder of forbidden-apis:
3
- # $ ant generate-internal
1
+ # (C) Copyright Uwe Schindler (Generics Policeman) and others.
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.
4
14
5
- # This file contains all internal packages listed in Security.getProperty("package.access") of Java version 24 (extracted from build 24).
15
+ # This file is no longer autogenerated starting from Java 24 because SecurityManager was removed
16
+ # and therefore relevant system properties used to generate the package list.
6
17
7
18
@defaultMessage non-public internal runtime class in Java 24
8
19
20
+ sun.misc.**
21
+ sun.reflect.**
Original file line number Diff line number Diff line change @@ -53,6 +53,14 @@ public final class InternalApiGen {
53
53
.append ("@defaultMessage non-public internal runtime class in Java " ).append (javaVersion ).append (NL )
54
54
.append (NL )
55
55
.toString ();
56
+ try {
57
+ int v = Integer .parseInt (javaVersion );
58
+ if (v >= 24 ) {
59
+ throw new IllegalArgumentException ("InternalApiGen only works till Java 23, for later versions use the generated file from Java 23." );
60
+ }
61
+ } catch (NumberFormatException nfe ) {
62
+ // pass
63
+ }
56
64
}
57
65
58
66
private void parsePackages (String packagesStr , Set <String > packages ) {
You can’t perform that action at this time.
0 commit comments