mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-18 01:54:47 +02:00
8067223: [TESTBUG] Rename Whitebox API package
Reviewed-by: dholmes, kvn
This commit is contained in:
parent
f8fb571307
commit
ada58d13f7
36 changed files with 1394 additions and 72 deletions
|
@ -32,8 +32,9 @@ import java.util.function.Function;
|
|||
import java.security.BasicPermission;
|
||||
import java.util.Objects;
|
||||
|
||||
import sun.hotspot.parser.DiagnosticCommand;
|
||||
import jdk.test.whitebox.parser.DiagnosticCommand;
|
||||
|
||||
@Deprecated
|
||||
public class WhiteBox {
|
||||
@SuppressWarnings("serial")
|
||||
public static class WhiteBoxPermission extends BasicPermission {
|
||||
|
@ -58,7 +59,7 @@ public class WhiteBox {
|
|||
@SuppressWarnings("removal")
|
||||
SecurityManager sm = System.getSecurityManager();
|
||||
if (sm != null) {
|
||||
sm.checkPermission(new WhiteBoxPermission("getInstance"));
|
||||
throw new SecurityException("can't use old whitebox with SecurityManager, please switch to jdk.test.whitebox.WhiteBox");
|
||||
}
|
||||
return instance;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue