8211122: Reduce the number of internal classes made accessible to jdk.unsupported
Reviewed-by: alanb, dfuchs, kvn
--- a/src/java.base/share/classes/com/sun/crypto/provider/SealedObjectForKeyProtector.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/com/sun/crypto/provider/SealedObjectForKeyProtector.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
package com.sun.crypto.provider;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import java.io.*;
import java.security.*;
--- a/src/java.base/share/classes/java/io/Console.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/Console.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,8 +27,8 @@
import java.util.*;
import java.nio.charset.Charset;
-import jdk.internal.misc.JavaIOAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOAccess;
+import jdk.internal.access.SharedSecrets;
import sun.nio.cs.StreamDecoder;
import sun.nio.cs.StreamEncoder;
--- a/src/java.base/share/classes/java/io/DeleteOnExitHook.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/DeleteOnExitHook.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,8 +25,8 @@
package java.io;
import java.util.*;
-import java.io.File;
-import jdk.internal.misc.SharedSecrets;
+
+import jdk.internal.access.SharedSecrets;
/**
* This class holds a set of filenames to be deleted on VM exit through a shutdown hook.
--- a/src/java.base/share/classes/java/io/FileCleanable.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/FileCleanable.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,8 +25,8 @@
package java.io;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.CleanerFactory;
import jdk.internal.ref.PhantomCleanable;
--- a/src/java.base/share/classes/java/io/FileDescriptor.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/FileDescriptor.java Tue Nov 06 10:01:16 2018 -0800
@@ -29,8 +29,8 @@
import java.util.List;
import java.util.Objects;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.PhantomCleanable;
/**
--- a/src/java.base/share/classes/java/io/FileOutputStream.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/FileOutputStream.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,8 +26,8 @@
package java.io;
import java.nio.channels.FileChannel;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
import sun.nio.ch.FileChannelImpl;
--- a/src/java.base/share/classes/java/io/FilePermission.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/FilePermission.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,8 +34,8 @@
import java.util.Vector;
import java.util.concurrent.ConcurrentHashMap;
-import jdk.internal.misc.JavaIOFilePermissionAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFilePermissionAccess;
+import jdk.internal.access.SharedSecrets;
import sun.nio.fs.DefaultFileSystemProvider;
import sun.security.action.GetPropertyAction;
import sun.security.util.FilePermCompat;
--- a/src/java.base/share/classes/java/io/ObjectInputFilter.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/ObjectInputFilter.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,7 +34,7 @@
import java.util.Optional;
import java.util.function.Function;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* Filter classes, array lengths, and graph metrics during deserialization.
--- a/src/java.base/share/classes/java/io/ObjectInputStream.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/ObjectInputStream.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -44,7 +44,7 @@
import static java.io.ObjectStreamClass.processQueue;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.Unsafe;
import sun.reflect.misc.ReflectUtil;
--- a/src/java.base/share/classes/java/io/ObjectStreamClass.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/ObjectStreamClass.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -57,9 +57,9 @@
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
import jdk.internal.reflect.ReflectionFactory;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
import sun.reflect.misc.ReflectUtil;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaSecurityAccess;
import static java.io.ObjectStreamField.*;
/**
--- a/src/java.base/share/classes/java/io/RandomAccessFile.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/io/RandomAccessFile.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1994, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1994, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,9 +26,9 @@
package java.io;
import java.nio.channels.FileChannel;
-import java.util.concurrent.atomic.AtomicBoolean;
-import jdk.internal.misc.JavaIORandomAccessFileAccess;
-import jdk.internal.misc.SharedSecrets;
+
+import jdk.internal.access.JavaIORandomAccessFileAccess;
+import jdk.internal.access.SharedSecrets;
import sun.nio.ch.FileChannelImpl;
--- a/src/java.base/share/classes/java/lang/Runtime.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/Runtime.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,16 +27,14 @@
import java.io.*;
import java.math.BigInteger;
-import java.util.ArrayList;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
-import java.util.Collections;
import java.util.List;
import java.util.Optional;
import java.util.StringTokenizer;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
--- a/src/java.base/share/classes/java/lang/StackFrameInfo.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/StackFrameInfo.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -24,10 +24,9 @@
*/
package java.lang;
-import jdk.internal.misc.JavaLangInvokeAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangInvokeAccess;
+import jdk.internal.access.SharedSecrets;
-import static java.lang.StackWalker.Option.*;
import java.lang.StackWalker.StackFrame;
import java.lang.invoke.MethodType;
--- a/src/java.base/share/classes/java/lang/System.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/System.java Tue Nov 06 10:01:16 2018 -0800
@@ -66,8 +66,8 @@
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
import jdk.internal.HotSpotIntrinsicCandidate;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
import jdk.internal.logger.LoggerFinderLoader;
import jdk.internal.logger.LazyLoggers;
--- a/src/java.base/share/classes/java/lang/Thread.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/Thread.java Tue Nov 06 10:01:16 2018 -0800
@@ -230,7 +230,7 @@
private volatile Interruptible blocker;
private final Object blockerLock = new Object();
- /* Set the blocker field; invoked via jdk.internal.misc.SharedSecrets
+ /* Set the blocker field; invoked via jdk.internal.access.SharedSecrets
* from java.nio code
*/
static void blockedOn(Interruptible b) {
--- a/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,8 +25,8 @@
package java.lang.invoke;
-import jdk.internal.misc.JavaLangInvokeAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangInvokeAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.org.objectweb.asm.AnnotationVisitor;
import jdk.internal.org.objectweb.asm.ClassWriter;
import jdk.internal.org.objectweb.asm.MethodVisitor;
--- a/src/java.base/share/classes/java/lang/invoke/MethodHandles.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/invoke/MethodHandles.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
package java.lang.invoke;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.IllegalAccessLogger;
import jdk.internal.org.objectweb.asm.ClassReader;
import jdk.internal.reflect.CallerSensitive;
--- a/src/java.base/share/classes/java/lang/module/ModuleDescriptor.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/module/ModuleDescriptor.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -2603,8 +2603,8 @@
* Setup the shared secret to allow code in other packages access
* private package methods in java.lang.module.
*/
- jdk.internal.misc.SharedSecrets
- .setJavaLangModuleAccess(new jdk.internal.misc.JavaLangModuleAccess() {
+ jdk.internal.access.SharedSecrets
+ .setJavaLangModuleAccess(new jdk.internal.access.JavaLangModuleAccess() {
@Override
public Builder newModuleBuilder(String mn,
boolean strict,
--- a/src/java.base/share/classes/java/lang/ref/Finalizer.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/ref/Finalizer.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,8 +27,8 @@
import java.security.PrivilegedAction;
import java.security.AccessController;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
final class Finalizer extends FinalReference<Object> { /* Package-private; must be in
--- a/src/java.base/share/classes/java/lang/ref/Reference.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/ref/Reference.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,8 +27,8 @@
import jdk.internal.vm.annotation.ForceInline;
import jdk.internal.HotSpotIntrinsicCandidate;
-import jdk.internal.misc.JavaLangRefAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangRefAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.Cleaner;
/**
--- a/src/java.base/share/classes/java/lang/reflect/Constructor.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/Constructor.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,7 @@
package java.lang.reflect;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.ConstructorAccessor;
import jdk.internal.reflect.Reflection;
--- a/src/java.base/share/classes/java/lang/reflect/Executable.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/Executable.java Tue Nov 06 10:01:16 2018 -0800
@@ -33,7 +33,7 @@
import java.util.stream.Stream;
import java.util.stream.Collectors;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import sun.reflect.annotation.AnnotationParser;
import sun.reflect.annotation.AnnotationSupport;
import sun.reflect.annotation.TypeAnnotationParser;
--- a/src/java.base/share/classes/java/lang/reflect/Field.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/Field.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,7 @@
package java.lang.reflect;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.FieldAccessor;
import jdk.internal.reflect.Reflection;
--- a/src/java.base/share/classes/java/lang/reflect/Method.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/Method.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,7 @@
package java.lang.reflect;
import jdk.internal.HotSpotIntrinsicCandidate;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.MethodAccessor;
import jdk.internal.reflect.Reflection;
--- a/src/java.base/share/classes/java/lang/reflect/Proxy.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/Proxy.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -40,9 +40,9 @@
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.loader.BootLoader;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
import jdk.internal.module.Modules;
import jdk.internal.misc.VM;
import jdk.internal.reflect.CallerSensitive;
--- a/src/java.base/share/classes/java/lang/reflect/UndeclaredThrowableException.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/lang/reflect/UndeclaredThrowableException.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,7 +29,7 @@
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.ObjectStreamField;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* Thrown by a method invocation on a proxy instance if its invocation
--- a/src/java.base/share/classes/java/net/HttpCookie.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/HttpCookie.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -32,11 +32,10 @@
import java.util.TimeZone;
import java.util.Calendar;
import java.util.GregorianCalendar;
-import java.util.Date;
import java.util.Locale;
import java.util.Objects;
-import jdk.internal.misc.JavaNetHttpCookieAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetHttpCookieAccess;
+import jdk.internal.access.SharedSecrets;
/**
* An HttpCookie object represents an HTTP cookie, which carries state
--- a/src/java.base/share/classes/java/net/InetAddress.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/InetAddress.java Tue Nov 06 10:01:16 2018 -0800
@@ -46,8 +46,8 @@
import java.util.concurrent.ConcurrentSkipListSet;
import java.util.concurrent.atomic.AtomicLong;
-import jdk.internal.misc.JavaNetInetAddressAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetInetAddressAccess;
+import jdk.internal.access.SharedSecrets;
import sun.security.action.*;
import sun.net.InetAddressCachePolicy;
import sun.net.util.IPAddressUtil;
--- a/src/java.base/share/classes/java/net/ServerSocket.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/ServerSocket.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,8 +25,8 @@
package java.net;
-import jdk.internal.misc.JavaNetSocketAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetSocketAccess;
+import jdk.internal.access.SharedSecrets;
import java.io.FileDescriptor;
import java.io.IOException;
--- a/src/java.base/share/classes/java/net/SocketCleanable.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/SocketCleanable.java Tue Nov 06 10:01:16 2018 -0800
@@ -24,8 +24,8 @@
*/
package java.net;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.CleanerFactory;
import jdk.internal.ref.PhantomCleanable;
--- a/src/java.base/share/classes/java/net/URI.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/URI.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -37,8 +37,8 @@
import java.nio.charset.CodingErrorAction;
import java.nio.charset.CharacterCodingException;
import java.text.Normalizer;
-import jdk.internal.misc.JavaNetUriAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetUriAccess;
+import jdk.internal.access.SharedSecrets;
import sun.nio.cs.ThreadLocalCoders;
import java.lang.Character; // for javadoc
--- a/src/java.base/share/classes/java/net/URL.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/URL.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -41,8 +41,8 @@
import java.util.ServiceConfigurationError;
import java.util.ServiceLoader;
-import jdk.internal.misc.JavaNetURLAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetURLAccess;
+import jdk.internal.access.SharedSecrets;
import sun.security.util.SecurityConstants;
import sun.security.action.GetPropertyAction;
--- a/src/java.base/share/classes/java/net/URLClassLoader.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/net/URLClassLoader.java Tue Nov 06 10:01:16 2018 -0800
@@ -52,8 +52,8 @@
import jdk.internal.loader.Resource;
import jdk.internal.loader.URLClassPath;
-import jdk.internal.misc.JavaNetURLClassLoaderAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetURLClassLoaderAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.perf.PerfCounter;
import sun.net.www.ParseUtil;
import sun.security.util.SecurityConstants;
--- a/src/java.base/share/classes/java/nio/Bits.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/nio/Bits.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,9 +25,9 @@
package java.nio;
-import jdk.internal.misc.JavaLangRefAccess;
-import jdk.internal.misc.JavaNioAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangRefAccess;
+import jdk.internal.access.JavaNioAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.Unsafe;
import jdk.internal.misc.VM;
--- a/src/java.base/share/classes/java/nio/Buffer.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/nio/Buffer.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,8 +26,8 @@
package java.nio;
import jdk.internal.HotSpotIntrinsicCandidate;
-import jdk.internal.misc.JavaNioAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNioAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.Unsafe;
import java.util.Spliterator;
--- a/src/java.base/share/classes/java/nio/channels/spi/AbstractInterruptibleChannel.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/nio/channels/spi/AbstractInterruptibleChannel.java Tue Nov 06 10:01:16 2018 -0800
@@ -30,7 +30,7 @@
import java.io.IOException;
import java.nio.channels.*;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import sun.nio.ch.Interruptible;
@@ -203,7 +203,7 @@
}
- // -- jdk.internal.misc.SharedSecrets --
+ // -- jdk.internal.access.SharedSecrets --
static void blockedOn(Interruptible intr) { // package-private
SharedSecrets.getJavaLangAccess().blockedOn(intr);
}
--- a/src/java.base/share/classes/java/nio/file/Files.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/nio/file/Files.java Tue Nov 06 10:01:16 2018 -0800
@@ -3128,8 +3128,8 @@
*/
private static final int MAX_BUFFER_SIZE = Integer.MAX_VALUE - 8;
- private static final jdk.internal.misc.JavaLangAccess JLA =
- jdk.internal.misc.SharedSecrets.getJavaLangAccess();
+ private static final jdk.internal.access.JavaLangAccess JLA =
+ jdk.internal.access.SharedSecrets.getJavaLangAccess();
/**
* Reads all the bytes from an input stream. Uses {@code initialSize} as a hint
--- a/src/java.base/share/classes/java/security/PrivilegedActionException.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/security/PrivilegedActionException.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,7 +29,7 @@
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.ObjectStreamField;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* This exception is thrown by
--- a/src/java.base/share/classes/java/security/ProtectionDomain.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/security/ProtectionDomain.java Tue Nov 06 10:01:16 2018 -0800
@@ -32,8 +32,8 @@
import java.util.Map;
import java.util.Objects;
import java.util.WeakHashMap;
-import jdk.internal.misc.JavaSecurityAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
+import jdk.internal.access.SharedSecrets;
import sun.security.action.GetPropertyAction;
import sun.security.provider.PolicyFile;
import sun.security.util.Debug;
--- a/src/java.base/share/classes/java/security/Security.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/security/Security.java Tue Nov 06 10:01:16 2018 -0800
@@ -30,7 +30,7 @@
import java.io.*;
import java.net.URL;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.util.StaticProperty;
import sun.security.util.Debug;
import sun.security.util.PropertyExpander;
--- a/src/java.base/share/classes/java/util/ArrayDeque.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/ArrayDeque.java Tue Nov 06 10:01:16 2018 -0800
@@ -37,8 +37,8 @@
import java.io.Serializable;
import java.util.function.Consumer;
import java.util.function.Predicate;
-import java.util.function.UnaryOperator;
-import jdk.internal.misc.SharedSecrets;
+
+import jdk.internal.access.SharedSecrets;
/**
* Resizable-array implementation of the {@link Deque} interface. Array
--- a/src/java.base/share/classes/java/util/ArrayList.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/ArrayList.java Tue Nov 06 10:01:16 2018 -0800
@@ -28,7 +28,7 @@
import java.util.function.Consumer;
import java.util.function.Predicate;
import java.util.function.UnaryOperator;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* Resizable-array implementation of the {@code List} interface. Implements
--- a/src/java.base/share/classes/java/util/EnumMap.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/EnumMap.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
package java.util;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* A specialized {@link Map} implementation for use with enum type keys. All
--- a/src/java.base/share/classes/java/util/EnumSet.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/EnumSet.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
package java.util;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* A specialized {@link Set} implementation for use with enum types. All of
--- a/src/java.base/share/classes/java/util/HashMap.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/HashMap.java Tue Nov 06 10:01:16 2018 -0800
@@ -34,7 +34,7 @@
import java.util.function.BiFunction;
import java.util.function.Consumer;
import java.util.function.Function;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* Hash table based implementation of the {@code Map} interface. This
--- a/src/java.base/share/classes/java/util/HashSet.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/HashSet.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,7 @@
package java.util;
import java.io.InvalidObjectException;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* This class implements the {@code Set} interface, backed by a hash table
--- a/src/java.base/share/classes/java/util/Hashtable.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/Hashtable.java Tue Nov 06 10:01:16 2018 -0800
@@ -29,7 +29,7 @@
import java.util.function.BiConsumer;
import java.util.function.Function;
import java.util.function.BiFunction;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* This class implements a hash table, which maps keys to values. Any
--- a/src/java.base/share/classes/java/util/IdentityHashMap.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/IdentityHashMap.java Tue Nov 06 10:01:16 2018 -0800
@@ -29,7 +29,7 @@
import java.util.function.BiConsumer;
import java.util.function.BiFunction;
import java.util.function.Consumer;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* This class implements the {@code Map} interface with a hash table, using
--- a/src/java.base/share/classes/java/util/ImmutableCollections.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/ImmutableCollections.java Tue Nov 06 10:01:16 2018 -0800
@@ -35,7 +35,7 @@
import java.util.function.Function;
import java.util.function.Predicate;
import java.util.function.UnaryOperator;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
import jdk.internal.vm.annotation.Stable;
--- a/src/java.base/share/classes/java/util/PriorityQueue.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/PriorityQueue.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,7 +27,7 @@
import java.util.function.Consumer;
import java.util.function.Predicate;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* An unbounded priority {@linkplain Queue queue} based on a priority heap.
--- a/src/java.base/share/classes/java/util/Properties.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/Properties.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -46,7 +46,7 @@
import java.util.function.BiFunction;
import java.util.function.Function;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.Unsafe;
import jdk.internal.util.xml.PropertiesDefaultHandler;
--- a/src/java.base/share/classes/java/util/ResourceBundle.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/ResourceBundle.java Tue Nov 06 10:01:16 2018 -0800
@@ -66,8 +66,8 @@
import java.util.stream.Stream;
import jdk.internal.loader.BootLoader;
-import jdk.internal.misc.JavaUtilResourceBundleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaUtilResourceBundleAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
import sun.security.action.GetPropertyAction;
--- a/src/java.base/share/classes/java/util/ServiceLoader.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/ServiceLoader.java Tue Nov 06 10:01:16 2018 -0800
@@ -47,8 +47,8 @@
import jdk.internal.loader.BootLoader;
import jdk.internal.loader.ClassLoaders;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
import jdk.internal.module.ServicesCatalog;
import jdk.internal.module.ServicesCatalog.ServiceProvider;
--- a/src/java.base/share/classes/java/util/UUID.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/UUID.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,8 +27,8 @@
import java.security.*;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
/**
* A class that represents an immutable universally unique identifier (UUID).
--- a/src/java.base/share/classes/java/util/concurrent/CopyOnWriteArrayList.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/concurrent/CopyOnWriteArrayList.java Tue Nov 06 10:01:16 2018 -0800
@@ -51,7 +51,7 @@
import java.util.function.Consumer;
import java.util.function.Predicate;
import java.util.function.UnaryOperator;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* A thread-safe variant of {@link java.util.ArrayList} in which all mutative
--- a/src/java.base/share/classes/java/util/concurrent/PriorityBlockingQueue.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/concurrent/PriorityBlockingQueue.java Tue Nov 06 10:01:16 2018 -0800
@@ -52,7 +52,7 @@
import java.util.concurrent.locks.ReentrantLock;
import java.util.function.Consumer;
import java.util.function.Predicate;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* An unbounded {@linkplain BlockingQueue blocking queue} that uses
--- a/src/java.base/share/classes/java/util/jar/JarFile.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/jar/JarFile.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,8 +25,8 @@
package java.util.jar;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaUtilZipFileAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaUtilZipFileAccess;
import sun.security.action.GetPropertyAction;
import sun.security.util.ManifestEntryVerifier;
import sun.security.util.SignatureFileVerifier;
@@ -172,7 +172,7 @@
// Set up JavaUtilJarAccess in SharedSecrets
SharedSecrets.setJavaUtilJarAccess(new JavaUtilJarAccessImpl());
// Get JavaUtilZipFileAccess from SharedSecrets
- JUZFA = jdk.internal.misc.SharedSecrets.getJavaUtilZipFileAccess();
+ JUZFA = SharedSecrets.getJavaUtilZipFileAccess();
// multi-release jar file versions >= 9
BASE_VERSION = Runtime.Version.parse(Integer.toString(8));
BASE_VERSION_FEATURE = BASE_VERSION.feature();
--- a/src/java.base/share/classes/java/util/jar/JavaUtilJarAccessImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/jar/JavaUtilJarAccessImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -30,7 +30,7 @@
import java.security.CodeSource;
import java.util.Enumeration;
import java.util.List;
-import jdk.internal.misc.JavaUtilJarAccess;
+import jdk.internal.access.JavaUtilJarAccess;
class JavaUtilJarAccessImpl implements JavaUtilJarAccess {
public boolean jarFileHasClassPathAttribute(JarFile jar) throws IOException {
--- a/src/java.base/share/classes/java/util/spi/AbstractResourceBundleProvider.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/spi/AbstractResourceBundleProvider.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,8 +25,8 @@
package java.util.spi;
-import jdk.internal.misc.JavaUtilResourceBundleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaUtilResourceBundleAccess;
+import jdk.internal.access.SharedSecrets;
import java.io.IOException;
import java.io.InputStream;
--- a/src/java.base/share/classes/java/util/zip/ZipCoder.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/zip/ZipCoder.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -41,8 +41,8 @@
class ZipCoder {
- private static final jdk.internal.misc.JavaLangAccess JLA =
- jdk.internal.misc.SharedSecrets.getJavaLangAccess();
+ private static final jdk.internal.access.JavaLangAccess JLA =
+ jdk.internal.access.SharedSecrets.getJavaLangAccess();
static final class UTF8 extends ZipCoder {
--- a/src/java.base/share/classes/java/util/zip/ZipFile.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/java/util/zip/ZipFile.java Tue Nov 06 10:01:16 2018 -0800
@@ -58,9 +58,9 @@
import java.util.jar.JarEntry;
import java.util.stream.Stream;
import java.util.stream.StreamSupport;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.JavaUtilZipFileAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.JavaUtilZipFileAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
import jdk.internal.perf.PerfCounter;
import jdk.internal.ref.CleanerFactory;
@@ -1071,7 +1071,7 @@
}
}
);
- JLA = jdk.internal.misc.SharedSecrets.getJavaLangAccess();
+ JLA = SharedSecrets.getJavaLangAccess();
isWindows = VM.getSavedProperty("os.name").contains("Windows");
}
--- a/src/java.base/share/classes/javax/crypto/SealedObject.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/javax/crypto/SealedObject.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
package javax.crypto;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import java.io.*;
import java.security.AlgorithmParameters;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaAWTAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+public interface JavaAWTAccess {
+
+ // Returns the AppContext used for applet logging isolation, or null if
+ // no isolation is required.
+ // If there's no applet, or if the caller is a stand alone application,
+ // or running in the main app context, returns null.
+ // Otherwise, returns the AppContext of the calling applet.
+ public Object getAppletContext();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaAWTFontAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/**
+ * SharedSecrets interface used for the access from java.text.Bidi
+ */
+
+package jdk.internal.access;
+
+public interface JavaAWTFontAccess {
+
+ // java.awt.font.TextAttribute constants
+ public Object getTextAttributeConstant(String name);
+
+ // java.awt.font.NumericShaper
+ public void shape(Object shaper, char[] text, int start, int count);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaBeansAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Method;
+
+public interface JavaBeansAccess {
+ /**
+ * Returns the getter method for a property of the given name
+ * @param clazz The JavaBeans class
+ * @param property The property name
+ * @return The resolved property getter method
+ * @throws Exception
+ */
+ Method getReadMethod(Class<?> clazz, String property) throws Exception;
+
+ /**
+ * Return the <b>value</b> attribute of the associated
+ * <code>@ConstructorProperties</code> annotation if that is present.
+ * @param ctr The constructor to extract the annotation value from
+ * @return The {@code value} attribute of the <code>@ConstructorProperties</code>
+ * annotation or {@code null} if the constructor is not annotated by
+ * this annotation or the annotation is not accessible.
+ */
+ String[] getConstructorPropertiesValue(Constructor<?> ctr);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaIOAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,34 @@
+/*
+ * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.Console;
+import java.nio.charset.Charset;
+
+public interface JavaIOAccess {
+ public Console console();
+ public Charset charset();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaIOFileDescriptorAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,49 @@
+/*
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.internal.access;
+
+import java.io.FileDescriptor;
+import java.io.IOException;
+
+import jdk.internal.ref.PhantomCleanable;
+
+/*
+ * @author Chris Hegarty
+ */
+
+public interface JavaIOFileDescriptorAccess {
+ public void set(FileDescriptor fdo, int fd);
+ public int get(FileDescriptor fdo);
+ public void setAppend(FileDescriptor fdo, boolean append);
+ public boolean getAppend(FileDescriptor fdo);
+ public void close(FileDescriptor fdo) throws IOException;
+ public void registerCleanup(FileDescriptor fdo);
+ public void registerCleanup(FileDescriptor fdo, PhantomCleanable<FileDescriptor> cleanable);
+ public void unregisterCleanup(FileDescriptor fdo);
+
+ // Only valid on Windows
+ public void setHandle(FileDescriptor fdo, long handle);
+ public long getHandle(FileDescriptor fdo);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaIOFilePermissionAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.internal.access;
+
+import java.io.FilePermission;
+
+public interface JavaIOFilePermissionAccess {
+
+ /**
+ * Returns a new FilePermission plus an alternative path.
+ *
+ * @param input the input
+ * @return the new FilePermission plus the alt path (as npath2)
+ * or the input itself if no alt path is available.
+ */
+ FilePermission newPermPlusAltPath(FilePermission input);
+
+ /**
+ * Returns a new FilePermission using an alternative path.
+ *
+ * @param input the input
+ * @return the new FilePermission using the alt path (as npath)
+ * or null if no alt path is available
+ */
+ FilePermission newPermUsingAltPath(FilePermission input);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaIORandomAccessFileAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.File;
+import java.io.IOException;
+import java.io.RandomAccessFile;
+
+public interface JavaIORandomAccessFileAccess {
+ public RandomAccessFile openAndDelete(File file, String mode)
+ throws IOException;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaLangAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,314 @@
+/*
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.lang.annotation.Annotation;
+import java.lang.module.ModuleDescriptor;
+import java.lang.reflect.Executable;
+import java.lang.reflect.Method;
+import java.net.URI;
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.Charset;
+import java.security.AccessControlContext;
+import java.security.ProtectionDomain;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.stream.Stream;
+
+import jdk.internal.module.ServicesCatalog;
+import jdk.internal.reflect.ConstantPool;
+import sun.reflect.annotation.AnnotationType;
+import sun.nio.ch.Interruptible;
+
+public interface JavaLangAccess {
+
+ /**
+ * Returns the list of {@code Method} objects for the declared public
+ * methods of this class or interface that have the specified method name
+ * and parameter types.
+ */
+ List<Method> getDeclaredPublicMethods(Class<?> klass, String name, Class<?>... parameterTypes);
+
+ /**
+ * Return the constant pool for a class.
+ */
+ ConstantPool getConstantPool(Class<?> klass);
+
+ /**
+ * Compare-And-Set the AnnotationType instance corresponding to this class.
+ * (This method only applies to annotation types.)
+ */
+ boolean casAnnotationType(Class<?> klass, AnnotationType oldType, AnnotationType newType);
+
+ /**
+ * Get the AnnotationType instance corresponding to this class.
+ * (This method only applies to annotation types.)
+ */
+ AnnotationType getAnnotationType(Class<?> klass);
+
+ /**
+ * Get the declared annotations for a given class, indexed by their types.
+ */
+ Map<Class<? extends Annotation>, Annotation> getDeclaredAnnotationMap(Class<?> klass);
+
+ /**
+ * Get the array of bytes that is the class-file representation
+ * of this Class' annotations.
+ */
+ byte[] getRawClassAnnotations(Class<?> klass);
+
+ /**
+ * Get the array of bytes that is the class-file representation
+ * of this Class' type annotations.
+ */
+ byte[] getRawClassTypeAnnotations(Class<?> klass);
+
+ /**
+ * Get the array of bytes that is the class-file representation
+ * of this Executable's type annotations.
+ */
+ byte[] getRawExecutableTypeAnnotations(Executable executable);
+
+ /**
+ * Returns the elements of an enum class or null if the
+ * Class object does not represent an enum type;
+ * the result is uncloned, cached, and shared by all callers.
+ */
+ <E extends Enum<E>> E[] getEnumConstantsShared(Class<E> klass);
+
+ /**
+ * Set current thread's blocker field.
+ */
+ void blockedOn(Interruptible b);
+
+ /**
+ * Registers a shutdown hook.
+ *
+ * It is expected that this method with registerShutdownInProgress=true
+ * is only used to register DeleteOnExitHook since the first file
+ * may be added to the delete on exit list by the application shutdown
+ * hooks.
+ *
+ * @param slot the slot in the shutdown hook array, whose element
+ * will be invoked in order during shutdown
+ * @param registerShutdownInProgress true to allow the hook
+ * to be registered even if the shutdown is in progress.
+ * @param hook the hook to be registered
+ *
+ * @throws IllegalStateException if shutdown is in progress and
+ * the slot is not valid to register.
+ */
+ void registerShutdownHook(int slot, boolean registerShutdownInProgress, Runnable hook);
+
+ /**
+ * Returns a new Thread with the given Runnable and an
+ * inherited AccessControlContext.
+ */
+ Thread newThreadWithAcc(Runnable target, AccessControlContext acc);
+
+ /**
+ * Invokes the finalize method of the given object.
+ */
+ void invokeFinalize(Object o) throws Throwable;
+
+ /**
+ * Returns the ConcurrentHashMap used as a storage for ClassLoaderValue(s)
+ * associated with the given class loader, creating it if it doesn't already exist.
+ */
+ ConcurrentHashMap<?, ?> createOrGetClassLoaderValueMap(ClassLoader cl);
+
+ /**
+ * Defines a class with the given name to a class loader.
+ */
+ Class<?> defineClass(ClassLoader cl, String name, byte[] b, ProtectionDomain pd, String source);
+
+ /**
+ * Returns a class loaded by the bootstrap class loader.
+ */
+ Class<?> findBootstrapClassOrNull(ClassLoader cl, String name);
+
+ /**
+ * Define a Package of the given name and module by the given class loader.
+ */
+ Package definePackage(ClassLoader cl, String name, Module module);
+
+ /**
+ * Invokes Long.fastUUID
+ */
+ String fastUUID(long lsb, long msb);
+
+ /**
+ * Record the non-exported packages of the modules in the given layer
+ */
+ void addNonExportedPackages(ModuleLayer layer);
+
+ /**
+ * Invalidate package access cache
+ */
+ void invalidatePackageAccessCache();
+
+ /**
+ * Defines a new module to the Java virtual machine. The module
+ * is defined to the given class loader.
+ *
+ * The URI is for information purposes only, it can be {@code null}.
+ */
+ Module defineModule(ClassLoader loader, ModuleDescriptor descriptor, URI uri);
+
+ /**
+ * Defines the unnamed module for the given class loader.
+ */
+ Module defineUnnamedModule(ClassLoader loader);
+
+ /**
+ * Updates the readability so that module m1 reads m2. The new read edge
+ * does not result in a strong reference to m2 (m2 can be GC'ed).
+ *
+ * This method is the same as m1.addReads(m2) but without a permission check.
+ */
+ void addReads(Module m1, Module m2);
+
+ /**
+ * Updates module m to read all unnamed modules.
+ */
+ void addReadsAllUnnamed(Module m);
+
+ /**
+ * Updates module m1 to export a package to module m2. The export does
+ * not result in a strong reference to m2 (m2 can be GC'ed).
+ */
+ void addExports(Module m1, String pkg, Module m2);
+
+ /**
+ * Updates a module m to export a package to all unnamed modules.
+ */
+ void addExportsToAllUnnamed(Module m, String pkg);
+
+ /**
+ * Updates module m1 to open a package to module m2. Opening the
+ * package does not result in a strong reference to m2 (m2 can be GC'ed).
+ */
+ void addOpens(Module m1, String pkg, Module m2);
+
+ /**
+ * Updates module m to open a package to all unnamed modules.
+ */
+ void addOpensToAllUnnamed(Module m, String pkg);
+
+ /**
+ * Updates module m to open all packages returned by the given iterator.
+ */
+ void addOpensToAllUnnamed(Module m, Iterator<String> packages);
+
+ /**
+ * Updates module m to use a service.
+ */
+ void addUses(Module m, Class<?> service);
+
+ /**
+ * Returns true if module m reflectively exports a package to other
+ */
+ boolean isReflectivelyExported(Module module, String pn, Module other);
+
+ /**
+ * Returns true if module m reflectively opens a package to other
+ */
+ boolean isReflectivelyOpened(Module module, String pn, Module other);
+
+ /**
+ * Returns the ServicesCatalog for the given Layer.
+ */
+ ServicesCatalog getServicesCatalog(ModuleLayer layer);
+
+ /**
+ * Returns an ordered stream of layers. The first element is the
+ * given layer, the remaining elements are its parents, in DFS order.
+ */
+ Stream<ModuleLayer> layers(ModuleLayer layer);
+
+ /**
+ * Returns a stream of the layers that have modules defined to the
+ * given class loader.
+ */
+ Stream<ModuleLayer> layers(ClassLoader loader);
+
+ /**
+ * Constructs a new {@code String} by decoding the specified subarray of
+ * bytes using the specified {@linkplain java.nio.charset.Charset charset}.
+ *
+ * The caller of this method shall relinquish and transfer the ownership of
+ * the byte array to the callee since the later will not make a copy.
+ *
+ * @param bytes the byte array source
+ * @param cs the Charset
+ * @return the newly created string
+ * @throws CharacterCodingException for malformed or unmappable bytes
+ */
+ String newStringNoRepl(byte[] bytes, Charset cs) throws CharacterCodingException;
+
+ /**
+ * Encode the given string into a sequence of bytes using the specified Charset.
+ *
+ * This method avoids copying the String's internal representation if the input
+ * is ASCII.
+ *
+ * This method throws CharacterCodingException instead of replacing when
+ * malformed input or unmappable characters are encountered.
+ *
+ * @param s the string to encode
+ * @param cs the charset
+ * @return the encoded bytes
+ * @throws CharacterCodingException for malformed input or unmappable characters
+ */
+ byte[] getBytesNoRepl(String s, Charset cs) throws CharacterCodingException;
+
+ /**
+ * Returns a new string by decoding from the given utf8 bytes array.
+ *
+ * @param off the index of the first byte to decode
+ * @param len the number of bytes to decode
+ * @return the newly created string
+ * @throws IllegalArgumentException for malformed or unmappable bytes.
+ */
+ String newStringUTF8NoRepl(byte[] bytes, int off, int len);
+
+ /**
+ * Encode the given string into a sequence of bytes using utf8.
+ *
+ * @param s the string to encode
+ * @return the encoded bytes in utf8
+ * @throws IllegalArgumentException for malformed surrogates
+ */
+ byte[] getBytesUTF8NoRepl(String s);
+
+ /**
+ * Set the cause of Throwable
+ * @param cause set t's cause to new value
+ */
+ void setCause(Throwable t, Throwable cause);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaLangInvokeAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,109 @@
+/*
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.lang.invoke.MethodType;
+import java.util.Map;
+
+public interface JavaLangInvokeAccess {
+ /**
+ * Create a new MemberName instance. Used by {@code StackFrameInfo}.
+ */
+ Object newMemberName();
+
+ /**
+ * Returns the name for the given MemberName. Used by {@code StackFrameInfo}.
+ */
+ String getName(Object mname);
+
+ /**
+ * Returns the {@code MethodType} for the given MemberName.
+ * Used by {@code StackFrameInfo}.
+ */
+ MethodType getMethodType(Object mname);
+
+ /**
+ * Returns the descriptor for the given MemberName.
+ * Used by {@code StackFrameInfo}.
+ */
+ String getMethodDescriptor(Object mname);
+
+ /**
+ * Returns {@code true} if the given MemberName is a native method.
+ * Used by {@code StackFrameInfo}.
+ */
+ boolean isNative(Object mname);
+
+ /**
+ * Returns the declaring class for the given MemberName.
+ * Used by {@code StackFrameInfo}.
+ */
+ Class<?> getDeclaringClass(Object mname);
+
+ /**
+ * Returns a {@code byte[]} representation of a class implementing
+ * DirectMethodHandle of each pairwise combination of {@code MethodType} and
+ * an {@code int} representing method type. Used by
+ * GenerateJLIClassesPlugin to generate such a class during the jlink phase.
+ */
+ byte[] generateDirectMethodHandleHolderClassBytes(String className,
+ MethodType[] methodTypes, int[] types);
+
+ /**
+ * Returns a {@code byte[]} representation of a class implementing
+ * DelegatingMethodHandles of each {@code MethodType} kind in the
+ * {@code methodTypes} argument. Used by GenerateJLIClassesPlugin to
+ * generate such a class during the jlink phase.
+ */
+ byte[] generateDelegatingMethodHandleHolderClassBytes(String className,
+ MethodType[] methodTypes);
+
+ /**
+ * Returns a {@code byte[]} representation of {@code BoundMethodHandle}
+ * species class implementing the signature defined by {@code types}. Used
+ * by GenerateJLIClassesPlugin to enable generation of such classes during
+ * the jlink phase. Should do some added validation since this string may be
+ * user provided.
+ */
+ Map.Entry<String, byte[]> generateConcreteBMHClassBytes(
+ final String types);
+
+ /**
+ * Returns a {@code byte[]} representation of a class implementing
+ * the zero and identity forms of all {@code LambdaForm.BasicType}s.
+ */
+ byte[] generateBasicFormsClassBytes(final String className);
+
+ /**
+ * Returns a {@code byte[]} representation of a class implementing
+ * the invoker forms for the set of supplied {@code invokerMethodTypes}
+ * and {@code callSiteMethodTypes}.
+ */
+ byte[] generateInvokersHolderClassBytes(String className,
+ MethodType[] invokerMethodTypes,
+ MethodType[] callSiteMethodTypes);
+
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaLangModuleAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,140 @@
+/*
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.PrintStream;
+import java.lang.module.Configuration;
+import java.lang.module.ModuleDescriptor;
+import java.lang.module.ModuleDescriptor.Exports;
+import java.lang.module.ModuleDescriptor.Opens;
+import java.lang.module.ModuleDescriptor.Requires;
+import java.lang.module.ModuleDescriptor.Provides;
+import java.lang.module.ModuleDescriptor.Version;
+import java.lang.module.ModuleFinder;
+import java.util.Collection;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+/**
+ * Provides access to non-public methods in java.lang.module.
+ */
+
+public interface JavaLangModuleAccess {
+
+ /**
+ * Creates a builder for building a module with the given module name.
+ *
+ * @param strict
+ * Indicates whether module names are checked or not
+ */
+ ModuleDescriptor.Builder newModuleBuilder(String mn,
+ boolean strict,
+ Set<ModuleDescriptor.Modifier> ms);
+
+ /**
+ * Returns a snapshot of the packages in the module.
+ */
+ Set<String> packages(ModuleDescriptor.Builder builder);
+
+ /**
+ * Adds a dependence on a module with the given (possibly un-parsable)
+ * version string.
+ */
+ void requires(ModuleDescriptor.Builder builder,
+ Set<Requires.Modifier> ms,
+ String mn,
+ String rawCompiledVersion);
+
+ /**
+ * Returns a {@code ModuleDescriptor.Requires} of the given modifiers
+ * and module name.
+ */
+ Requires newRequires(Set<Requires.Modifier> ms, String mn, Version v);
+
+ /**
+ * Returns an unqualified {@code ModuleDescriptor.Exports}
+ * of the given modifiers and package name source.
+ */
+ Exports newExports(Set<Exports.Modifier> ms,
+ String source);
+
+ /**
+ * Returns a qualified {@code ModuleDescriptor.Exports}
+ * of the given modifiers, package name source and targets.
+ */
+ Exports newExports(Set<Exports.Modifier> ms,
+ String source,
+ Set<String> targets);
+
+ /**
+ * Returns an unqualified {@code ModuleDescriptor.Opens}
+ * of the given modifiers and package name source.
+ */
+ Opens newOpens(Set<Opens.Modifier> ms, String source);
+
+ /**
+ * Returns a qualified {@code ModuleDescriptor.Opens}
+ * of the given modifiers, package name source and targets.
+ */
+ Opens newOpens(Set<Opens.Modifier> ms, String source, Set<String> targets);
+
+ /**
+ * Returns a {@code ModuleDescriptor.Provides}
+ * of the given service name and providers.
+ */
+ Provides newProvides(String service, List<String> providers);
+
+ /**
+ * Returns a new {@code ModuleDescriptor} instance.
+ */
+ ModuleDescriptor newModuleDescriptor(String name,
+ Version version,
+ Set<ModuleDescriptor.Modifier> ms,
+ Set<Requires> requires,
+ Set<Exports> exports,
+ Set<Opens> opens,
+ Set<String> uses,
+ Set<Provides> provides,
+ Set<String> packages,
+ String mainClass,
+ int hashCode);
+
+ /**
+ * Resolves a collection of root modules, with service binding
+ * and the empty configuration as the parent.
+ */
+ Configuration resolveAndBind(ModuleFinder finder,
+ Collection<String> roots,
+ PrintStream traceOutput);
+
+ /**
+ * Creates a configuration from a pre-generated readability graph.
+ */
+ Configuration newConfiguration(ModuleFinder finder,
+ Map<String, Set<String>> graph);
+
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaLangRefAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+public interface JavaLangRefAccess {
+
+ /**
+ * Wait for progress in {@link java.lang.ref.Reference}
+ * processing. If there aren't any pending {@link
+ * java.lang.ref.Reference}s, return immediately.
+ *
+ * @return {@code true} if there were any pending
+ * {@link java.lang.ref.Reference}s, {@code false} otherwise.
+ */
+ boolean waitForReferenceProcessing() throws InterruptedException;
+
+ /**
+ * Runs the finalization methods of any objects pending finalization.
+ *
+ * Invoked by Runtime.runFinalization()
+ */
+ void runFinalization();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetHttpCookieAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.net.HttpCookie;
+import java.util.List;
+
+public interface JavaNetHttpCookieAccess {
+ /*
+ * Constructs cookies from Set-Cookie or Set-Cookie2 header string,
+ * retaining the original header String in the cookie itself.
+ */
+ public List<HttpCookie> parse(String header);
+
+ /*
+ * Returns the original header this cookie was constructed from, if it was
+ * constructed by parsing a header, otherwise null.
+ */
+ public String header(HttpCookie cookie);
+}
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetInetAddressAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.net.InetAddress;
+import java.net.UnknownHostException;
+
+public interface JavaNetInetAddressAccess {
+ /**
+ * Return the original application specified hostname of
+ * the given InetAddress object.
+ */
+ String getOriginalHostName(InetAddress ia);
+
+ /**
+ * Get the InetAddress of the provided host. If an InetAddress is provided
+ * then it will be the default address returned for all calls to either
+ * form of getByName. This is required to maintain consistency when
+ * caching addresses and hostnames.
+ */
+ InetAddress getByName(String hostName, InetAddress hostAddress)
+ throws UnknownHostException;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetSocketAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.net.ServerSocket;
+import java.net.SocketImpl;
+
+public interface JavaNetSocketAccess {
+ /**
+ * Creates a ServerSocket associated with the given SocketImpl.
+ */
+ ServerSocket newServerSocket(SocketImpl impl);
+
+ /*
+ * Constructs a SocketImpl instance of the given class.
+ */
+ SocketImpl newSocketImpl(Class<? extends SocketImpl> implClass);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetURLAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.internal.access;
+
+import java.net.URL;
+import java.net.URLStreamHandler;
+
+public interface JavaNetURLAccess {
+ URLStreamHandler getHandler(URL u);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetURLClassLoaderAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,33 @@
+/*
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.net.URLClassLoader;
+import java.security.AccessControlContext;
+
+public interface JavaNetURLClassLoaderAccess {
+ AccessControlContext getAccessControlContext(URLClassLoader u);;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNetUriAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2006, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.net.URI;
+
+public interface JavaNetUriAccess {
+ /**
+ * Create a URI of pre-validated scheme and path.
+ */
+ URI create(String scheme, String path);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaNioAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.nio.Buffer;
+import java.nio.ByteBuffer;
+
+public interface JavaNioAccess {
+ /**
+ * Provides access to information on buffer usage.
+ */
+ interface BufferPool {
+ String getName();
+ long getCount();
+ long getTotalCapacity();
+ long getMemoryUsed();
+ }
+ BufferPool getDirectBufferPool();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaObjectInputFilterAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.ObjectInputFilter;
+
+/**
+ * Access to the alternative ObjectInputFilter.Config.createFilter2 for RMI.
+ */
+public interface JavaObjectInputFilterAccess {
+ /**
+ * Creates a filter from the pattern.
+ */
+ ObjectInputFilter createFilter2(String pattern);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaObjectInputStreamAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.InvalidClassException;
+import java.io.ObjectInputStream;
+
+/**
+ * Interface to specify methods for accessing {@code ObjectInputStream}.
+ */
+@FunctionalInterface
+public interface JavaObjectInputStreamAccess {
+ void checkArray(ObjectInputStream ois, Class<?> arrayType, int arrayLength)
+ throws InvalidClassException;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaSecurityAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.security.AccessControlContext;
+import java.security.PermissionCollection;
+import java.security.PrivilegedAction;
+import java.security.ProtectionDomain;
+
+public interface JavaSecurityAccess {
+
+ <T> T doIntersectionPrivilege(PrivilegedAction<T> action,
+ AccessControlContext stack,
+ AccessControlContext context);
+
+ <T> T doIntersectionPrivilege(PrivilegedAction<T> action,
+ AccessControlContext context);
+
+ ProtectionDomain[] getProtectDomains(AccessControlContext context);
+
+ interface ProtectionDomainCache {
+ void put(ProtectionDomain pd, PermissionCollection pc);
+ PermissionCollection get(ProtectionDomain pd);
+ }
+
+ /**
+ * Returns the ProtectionDomainCache.
+ */
+ ProtectionDomainCache getProtectionDomainCache();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaUtilJarAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.IOException;
+import java.net.URL;
+import java.security.CodeSource;
+import java.util.Enumeration;
+import java.util.List;
+import java.util.jar.Attributes;
+import java.util.jar.JarEntry;
+import java.util.jar.JarFile;
+import java.util.jar.Manifest;
+
+public interface JavaUtilJarAccess {
+ public boolean jarFileHasClassPathAttribute(JarFile jar) throws IOException;
+ public CodeSource[] getCodeSources(JarFile jar, URL url);
+ public CodeSource getCodeSource(JarFile jar, URL url, String name);
+ public Enumeration<String> entryNames(JarFile jar, CodeSource[] cs);
+ public Enumeration<JarEntry> entries2(JarFile jar);
+ public void setEagerValidation(JarFile jar, boolean eager);
+ public List<Object> getManifestDigests(JarFile jar);
+ public Attributes getTrustedAttributes(Manifest man, String name);
+ public void ensureInitialization(JarFile jar);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaUtilResourceBundleAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,66 @@
+/*
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.util.Locale;
+import java.util.ResourceBundle;
+
+/**
+ * Provides access to non-public methods in java.util.ResourceBundle.
+ */
+public interface JavaUtilResourceBundleAccess {
+ /**
+ * Sets the bundle's parent to the given parent.
+ */
+ void setParent(ResourceBundle bundle, ResourceBundle parent);
+
+ /**
+ * Returns the parent of the given bundle or null if the bundle has no parent.
+ */
+ ResourceBundle getParent(ResourceBundle bundle);
+
+ /**
+ * Sets the bundle's locale to the given locale.
+ */
+ void setLocale(ResourceBundle bundle, Locale locale);
+
+ /**
+ * Sets the bundle's base name to the given name.
+ */
+ void setName(ResourceBundle bundle, String name);
+
+ /**
+ * Returns a {@code ResourceBundle} of the given baseName and locale
+ * loaded on behalf of the given module with no caller module
+ * access check.
+ */
+ ResourceBundle getBundle(String baseName, Locale locale, Module module);
+
+ /**
+ * Instantiates a {@code ResourceBundle} of the given bundle class.
+ */
+ ResourceBundle newResourceBundle(Class<? extends ResourceBundle> bundleClass);
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaUtilZipFileAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import java.io.IOException;
+import java.util.Enumeration;
+import java.util.function.Function;
+import java.util.jar.JarEntry;
+import java.util.stream.Stream;
+import java.util.zip.ZipFile;
+
+public interface JavaUtilZipFileAccess {
+ public boolean startsWithLocHeader(ZipFile zip);
+ public String[] getMetaInfEntryNames(ZipFile zip);
+ public JarEntry getEntry(ZipFile zip, String name, Function<String, JarEntry> func);
+ public Enumeration<JarEntry> entries(ZipFile zip, Function<String, JarEntry> func);
+ public Stream<JarEntry> stream(ZipFile zip, Function<String, JarEntry> func);
+ public Stream<String> entryNameStream(ZipFile zip);
+}
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/JavaxCryptoSealedObjectAccess.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.internal.access;
+
+import javax.crypto.BadPaddingException;
+import javax.crypto.Cipher;
+import javax.crypto.IllegalBlockSizeException;
+import javax.crypto.SealedObject;
+import java.io.IOException;
+import java.io.ObjectInputStream;
+
+public interface JavaxCryptoSealedObjectAccess {
+ ObjectInputStream getExtObjectInputStream(
+ SealedObject sealed, Cipher cipher)
+ throws BadPaddingException, IllegalBlockSizeException, IOException;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/access/SharedSecrets.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,340 @@
+/*
+ * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.access;
+
+import javax.crypto.SealedObject;
+import java.io.ObjectInputFilter;
+import java.lang.module.ModuleDescriptor;
+import java.util.ResourceBundle;
+import java.util.jar.JarFile;
+import java.io.Console;
+import java.io.FileDescriptor;
+import java.io.FilePermission;
+import java.io.ObjectInputStream;
+import java.io.RandomAccessFile;
+import java.security.ProtectionDomain;
+import jdk.internal.misc.Unsafe;
+
+/** A repository of "shared secrets", which are a mechanism for
+ calling implementation-private methods in another package without
+ using reflection. A package-private class implements a public
+ interface and provides the ability to call package-private methods
+ within that package; the object implementing that interface is
+ provided through a third package to which access is restricted.
+ This framework avoids the primary disadvantage of using reflection
+ for this purpose, namely the loss of compile-time checking. */
+
+public class SharedSecrets {
+ private static final Unsafe unsafe = Unsafe.getUnsafe();
+ private static JavaUtilJarAccess javaUtilJarAccess;
+ private static JavaLangAccess javaLangAccess;
+ private static JavaLangModuleAccess javaLangModuleAccess;
+ private static JavaLangInvokeAccess javaLangInvokeAccess;
+ private static JavaLangRefAccess javaLangRefAccess;
+ private static JavaIOAccess javaIOAccess;
+ private static JavaNetInetAddressAccess javaNetInetAddressAccess;
+ private static JavaNetHttpCookieAccess javaNetHttpCookieAccess;
+ private static JavaNetSocketAccess javaNetSocketAccess;
+ private static JavaNetUriAccess javaNetUriAccess;
+ private static JavaNetURLAccess javaNetURLAccess;
+ private static JavaNetURLClassLoaderAccess javaNetURLClassLoaderAccess;
+ private static JavaNioAccess javaNioAccess;
+ private static JavaIOFileDescriptorAccess javaIOFileDescriptorAccess;
+ private static JavaIOFilePermissionAccess javaIOFilePermissionAccess;
+ private static JavaSecurityAccess javaSecurityAccess;
+ private static JavaUtilZipFileAccess javaUtilZipFileAccess;
+ private static JavaUtilResourceBundleAccess javaUtilResourceBundleAccess;
+ private static JavaAWTAccess javaAWTAccess;
+ private static JavaAWTFontAccess javaAWTFontAccess;
+ private static JavaBeansAccess javaBeansAccess;
+ private static JavaObjectInputStreamAccess javaObjectInputStreamAccess;
+ private static JavaObjectInputFilterAccess javaObjectInputFilterAccess;
+ private static JavaIORandomAccessFileAccess javaIORandomAccessFileAccess;
+ private static JavaxCryptoSealedObjectAccess javaxCryptoSealedObjectAccess;
+
+ public static JavaUtilJarAccess javaUtilJarAccess() {
+ if (javaUtilJarAccess == null) {
+ // Ensure JarFile is initialized; we know that that class
+ // provides the shared secret
+ unsafe.ensureClassInitialized(JarFile.class);
+ }
+ return javaUtilJarAccess;
+ }
+
+ public static void setJavaUtilJarAccess(JavaUtilJarAccess access) {
+ javaUtilJarAccess = access;
+ }
+
+ public static void setJavaLangAccess(JavaLangAccess jla) {
+ javaLangAccess = jla;
+ }
+
+ public static JavaLangAccess getJavaLangAccess() {
+ return javaLangAccess;
+ }
+
+ public static void setJavaLangInvokeAccess(JavaLangInvokeAccess jlia) {
+ javaLangInvokeAccess = jlia;
+ }
+
+ public static JavaLangInvokeAccess getJavaLangInvokeAccess() {
+ if (javaLangInvokeAccess == null) {
+ try {
+ Class<?> c = Class.forName("java.lang.invoke.MethodHandleImpl");
+ unsafe.ensureClassInitialized(c);
+ } catch (ClassNotFoundException e) {};
+ }
+ return javaLangInvokeAccess;
+ }
+
+ public static void setJavaLangModuleAccess(JavaLangModuleAccess jlrma) {
+ javaLangModuleAccess = jlrma;
+ }
+
+ public static JavaLangModuleAccess getJavaLangModuleAccess() {
+ if (javaLangModuleAccess == null) {
+ unsafe.ensureClassInitialized(ModuleDescriptor.class);
+ }
+ return javaLangModuleAccess;
+ }
+
+ public static void setJavaLangRefAccess(JavaLangRefAccess jlra) {
+ javaLangRefAccess = jlra;
+ }
+
+ public static JavaLangRefAccess getJavaLangRefAccess() {
+ return javaLangRefAccess;
+ }
+
+ public static void setJavaNetUriAccess(JavaNetUriAccess jnua) {
+ javaNetUriAccess = jnua;
+ }
+
+ public static JavaNetUriAccess getJavaNetUriAccess() {
+ if (javaNetUriAccess == null)
+ unsafe.ensureClassInitialized(java.net.URI.class);
+ return javaNetUriAccess;
+ }
+
+ public static void setJavaNetURLAccess(JavaNetURLAccess jnua) {
+ javaNetURLAccess = jnua;
+ }
+
+ public static JavaNetURLAccess getJavaNetURLAccess() {
+ if (javaNetURLAccess == null)
+ unsafe.ensureClassInitialized(java.net.URL.class);
+ return javaNetURLAccess;
+ }
+
+ public static void setJavaNetURLClassLoaderAccess(JavaNetURLClassLoaderAccess jnua) {
+ javaNetURLClassLoaderAccess = jnua;
+ }
+
+ public static JavaNetURLClassLoaderAccess getJavaNetURLClassLoaderAccess() {
+ if (javaNetURLClassLoaderAccess == null)
+ unsafe.ensureClassInitialized(java.net.URLClassLoader.class);
+ return javaNetURLClassLoaderAccess;
+ }
+
+ public static void setJavaNetInetAddressAccess(JavaNetInetAddressAccess jna) {
+ javaNetInetAddressAccess = jna;
+ }
+
+ public static JavaNetInetAddressAccess getJavaNetInetAddressAccess() {
+ if (javaNetInetAddressAccess == null)
+ unsafe.ensureClassInitialized(java.net.InetAddress.class);
+ return javaNetInetAddressAccess;
+ }
+
+ public static void setJavaNetHttpCookieAccess(JavaNetHttpCookieAccess a) {
+ javaNetHttpCookieAccess = a;
+ }
+
+ public static JavaNetHttpCookieAccess getJavaNetHttpCookieAccess() {
+ if (javaNetHttpCookieAccess == null)
+ unsafe.ensureClassInitialized(java.net.HttpCookie.class);
+ return javaNetHttpCookieAccess;
+ }
+
+ public static void setJavaNetSocketAccess(JavaNetSocketAccess jnsa) {
+ javaNetSocketAccess = jnsa;
+ }
+
+ public static JavaNetSocketAccess getJavaNetSocketAccess() {
+ if (javaNetSocketAccess == null)
+ unsafe.ensureClassInitialized(java.net.ServerSocket.class);
+ return javaNetSocketAccess;
+ }
+
+ public static void setJavaNioAccess(JavaNioAccess jna) {
+ javaNioAccess = jna;
+ }
+
+ public static JavaNioAccess getJavaNioAccess() {
+ if (javaNioAccess == null) {
+ // Ensure java.nio.Buffer is initialized, which provides the
+ // shared secret.
+ unsafe.ensureClassInitialized(java.nio.Buffer.class);
+ }
+ return javaNioAccess;
+ }
+
+ public static void setJavaIOAccess(JavaIOAccess jia) {
+ javaIOAccess = jia;
+ }
+
+ public static JavaIOAccess getJavaIOAccess() {
+ if (javaIOAccess == null) {
+ unsafe.ensureClassInitialized(Console.class);
+ }
+ return javaIOAccess;
+ }
+
+ public static void setJavaIOFileDescriptorAccess(JavaIOFileDescriptorAccess jiofda) {
+ javaIOFileDescriptorAccess = jiofda;
+ }
+
+ public static JavaIOFilePermissionAccess getJavaIOFilePermissionAccess() {
+ if (javaIOFilePermissionAccess == null)
+ unsafe.ensureClassInitialized(FilePermission.class);
+
+ return javaIOFilePermissionAccess;
+ }
+
+ public static void setJavaIOFilePermissionAccess(JavaIOFilePermissionAccess jiofpa) {
+ javaIOFilePermissionAccess = jiofpa;
+ }
+
+ public static JavaIOFileDescriptorAccess getJavaIOFileDescriptorAccess() {
+ if (javaIOFileDescriptorAccess == null)
+ unsafe.ensureClassInitialized(FileDescriptor.class);
+
+ return javaIOFileDescriptorAccess;
+ }
+
+ public static void setJavaSecurityAccess(JavaSecurityAccess jsa) {
+ javaSecurityAccess = jsa;
+ }
+
+ public static JavaSecurityAccess getJavaSecurityAccess() {
+ if (javaSecurityAccess == null) {
+ unsafe.ensureClassInitialized(ProtectionDomain.class);
+ }
+ return javaSecurityAccess;
+ }
+
+ public static JavaUtilZipFileAccess getJavaUtilZipFileAccess() {
+ if (javaUtilZipFileAccess == null)
+ unsafe.ensureClassInitialized(java.util.zip.ZipFile.class);
+ return javaUtilZipFileAccess;
+ }
+
+ public static void setJavaUtilZipFileAccess(JavaUtilZipFileAccess access) {
+ javaUtilZipFileAccess = access;
+ }
+
+ public static void setJavaAWTAccess(JavaAWTAccess jaa) {
+ javaAWTAccess = jaa;
+ }
+
+ public static JavaAWTAccess getJavaAWTAccess() {
+ // this may return null in which case calling code needs to
+ // provision for.
+ return javaAWTAccess;
+ }
+
+ public static void setJavaAWTFontAccess(JavaAWTFontAccess jafa) {
+ javaAWTFontAccess = jafa;
+ }
+
+ public static JavaAWTFontAccess getJavaAWTFontAccess() {
+ // this may return null in which case calling code needs to
+ // provision for.
+ return javaAWTFontAccess;
+ }
+
+ public static JavaBeansAccess getJavaBeansAccess() {
+ return javaBeansAccess;
+ }
+
+ public static void setJavaBeansAccess(JavaBeansAccess access) {
+ javaBeansAccess = access;
+ }
+
+ public static JavaUtilResourceBundleAccess getJavaUtilResourceBundleAccess() {
+ if (javaUtilResourceBundleAccess == null)
+ unsafe.ensureClassInitialized(ResourceBundle.class);
+ return javaUtilResourceBundleAccess;
+ }
+
+ public static void setJavaUtilResourceBundleAccess(JavaUtilResourceBundleAccess access) {
+ javaUtilResourceBundleAccess = access;
+ }
+
+ public static JavaObjectInputStreamAccess getJavaObjectInputStreamAccess() {
+ if (javaObjectInputStreamAccess == null) {
+ unsafe.ensureClassInitialized(ObjectInputStream.class);
+ }
+ return javaObjectInputStreamAccess;
+ }
+
+ public static void setJavaObjectInputStreamAccess(JavaObjectInputStreamAccess access) {
+ javaObjectInputStreamAccess = access;
+ }
+
+ public static JavaObjectInputFilterAccess getJavaObjectInputFilterAccess() {
+ if (javaObjectInputFilterAccess == null) {
+ unsafe.ensureClassInitialized(ObjectInputFilter.Config.class);
+ }
+ return javaObjectInputFilterAccess;
+ }
+
+ public static void setJavaObjectInputFilterAccess(JavaObjectInputFilterAccess access) {
+ javaObjectInputFilterAccess = access;
+ }
+
+ public static void setJavaIORandomAccessFileAccess(JavaIORandomAccessFileAccess jirafa) {
+ javaIORandomAccessFileAccess = jirafa;
+ }
+
+ public static JavaIORandomAccessFileAccess getJavaIORandomAccessFileAccess() {
+ if (javaIORandomAccessFileAccess == null) {
+ unsafe.ensureClassInitialized(RandomAccessFile.class);
+ }
+ return javaIORandomAccessFileAccess;
+ }
+
+ public static void setJavaxCryptoSealedObjectAccess(JavaxCryptoSealedObjectAccess jcsoa) {
+ javaxCryptoSealedObjectAccess = jcsoa;
+ }
+
+ public static JavaxCryptoSealedObjectAccess getJavaxCryptoSealedObjectAccess() {
+ if (javaxCryptoSealedObjectAccess == null) {
+ unsafe.ensureClassInitialized(SealedObject.class);
+ }
+ return javaxCryptoSealedObjectAccess;
+ }
+}
--- a/src/java.base/share/classes/jdk/internal/loader/AbstractClassLoaderValue.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/AbstractClassLoaderValue.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,8 +25,8 @@
package jdk.internal.loader;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import java.lang.reflect.UndeclaredThrowableException;
import java.util.Iterator;
--- a/src/java.base/share/classes/jdk/internal/loader/BootLoader.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/BootLoader.java Tue Nov 06 10:01:16 2018 -0800
@@ -36,14 +36,13 @@
import java.security.PrivilegedAction;
import java.util.Arrays;
import java.util.Enumeration;
-import java.util.Optional;
import java.util.concurrent.ConcurrentHashMap;
import java.util.jar.JarInputStream;
import java.util.jar.Manifest;
import java.util.stream.Stream;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.Modules;
import jdk.internal.module.ServicesCatalog;
import jdk.internal.util.StaticProperty;
--- a/src/java.base/share/classes/jdk/internal/loader/BuiltinClassLoader.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/BuiltinClassLoader.java Tue Nov 06 10:01:16 2018 -0800
@@ -60,7 +60,7 @@
import java.util.jar.Manifest;
import java.util.stream.Stream;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
import jdk.internal.module.ModulePatcher.PatchedModuleReader;
import jdk.internal.module.Resources;
--- a/src/java.base/share/classes/jdk/internal/loader/ClassLoaders.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/ClassLoaders.java Tue Nov 06 10:01:16 2018 -0800
@@ -33,8 +33,8 @@
import java.security.PermissionCollection;
import java.util.jar.Manifest;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.VM;
/**
--- a/src/java.base/share/classes/jdk/internal/loader/Loader.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/Loader.java Tue Nov 06 10:01:16 2018 -0800
@@ -60,7 +60,7 @@
import java.util.concurrent.ConcurrentHashMap;
import java.util.stream.Stream;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.Resources;
/**
--- a/src/java.base/share/classes/jdk/internal/loader/URLClassPath.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/loader/URLClassPath.java Tue Nov 06 10:01:16 2018 -0800
@@ -68,9 +68,9 @@
import java.util.jar.Attributes.Name;
import java.util.zip.ZipFile;
-import jdk.internal.misc.JavaNetURLAccess;
-import jdk.internal.misc.JavaUtilZipFileAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetURLAccess;
+import jdk.internal.access.JavaUtilZipFileAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.util.jar.InvalidJarIndexError;
import jdk.internal.util.jar.JarIndex;
import sun.net.util.URLUtil;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/java.base/share/classes/jdk/internal/misc/FileSystemOption.java Tue Nov 06 10:01:16 2018 -0800
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package jdk.internal.misc;
+
+import sun.nio.fs.ExtendedOptions;
+
+import java.nio.file.CopyOption;
+import java.nio.file.OpenOption;
+import java.nio.file.WatchEvent;
+
+/**
+ * Internal file system options for jdk.unsupported com.sun.nio.file API use.
+ */
+public final class FileSystemOption<T> {
+ public static final FileSystemOption<Void> INTERRUPTIBLE =
+ new FileSystemOption<>(ExtendedOptions.INTERRUPTIBLE);
+ public static final FileSystemOption<Void> NOSHARE_READ =
+ new FileSystemOption<>(ExtendedOptions.NOSHARE_READ);
+ public static final FileSystemOption<Void> NOSHARE_WRITE =
+ new FileSystemOption<>(ExtendedOptions.NOSHARE_WRITE);
+ public static final FileSystemOption<Void> NOSHARE_DELETE =
+ new FileSystemOption<>(ExtendedOptions.NOSHARE_DELETE);
+ public static final FileSystemOption<Void> FILE_TREE =
+ new FileSystemOption<>(ExtendedOptions.FILE_TREE);
+ public static final FileSystemOption<Void> DIRECT =
+ new FileSystemOption<>(ExtendedOptions.DIRECT);
+ public static final FileSystemOption<Integer> SENSITIVITY_HIGH =
+ new FileSystemOption<>(ExtendedOptions.SENSITIVITY_HIGH);
+ public static final FileSystemOption<Integer> SENSITIVITY_MEDIUM =
+ new FileSystemOption<>(ExtendedOptions.SENSITIVITY_MEDIUM);
+ public static final FileSystemOption<Integer> SENSITIVITY_LOW =
+ new FileSystemOption<>(ExtendedOptions.SENSITIVITY_LOW);
+
+ private final ExtendedOptions.InternalOption<T> internalOption;
+ private FileSystemOption(ExtendedOptions.InternalOption<T> option) {
+ this.internalOption = option;
+ }
+
+ /**
+ * Register this internal option as an OpenOption.
+ */
+ public void register(OpenOption option) {
+ internalOption.register(option);
+ }
+
+ /**
+ * Register this internal option as a CopyOption.
+ */
+ public void register(CopyOption option) {
+ internalOption.register(option);
+ }
+
+ /**
+ * Register this internal option as a WatchEvent.Modifier.
+ */
+ public void register(WatchEvent.Modifier option) {
+ internalOption.register(option);
+ }
+
+ /**
+ * Register this internal option as a WatchEvent.Modifier with the
+ * given parameter.
+ */
+ public void register(WatchEvent.Modifier option, T param) {
+ internalOption.register(option, param);
+ }
+}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaAWTAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-/*
- * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-public interface JavaAWTAccess {
-
- // Returns the AppContext used for applet logging isolation, or null if
- // no isolation is required.
- // If there's no applet, or if the caller is a stand alone application,
- // or running in the main app context, returns null.
- // Otherwise, returns the AppContext of the calling applet.
- public Object getAppletContext();
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaAWTFontAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,39 +0,0 @@
-/*
- * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/**
- * SharedSecrets interface used for the access from java.text.Bidi
- */
-
-package jdk.internal.misc;
-
-public interface JavaAWTFontAccess {
-
- // java.awt.font.TextAttribute constants
- public Object getTextAttributeConstant(String name);
-
- // java.awt.font.NumericShaper
- public void shape(Object shaper, char[] text, int start, int count);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaBeansAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-/*
- * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Method;
-
-public interface JavaBeansAccess {
- /**
- * Returns the getter method for a property of the given name
- * @param clazz The JavaBeans class
- * @param property The property name
- * @return The resolved property getter method
- * @throws Exception
- */
- Method getReadMethod(Class<?> clazz, String property) throws Exception;
-
- /**
- * Return the <b>value</b> attribute of the associated
- * <code>@ConstructorProperties</code> annotation if that is present.
- * @param ctr The constructor to extract the annotation value from
- * @return The {@code value} attribute of the <code>@ConstructorProperties</code>
- * annotation or {@code null} if the constructor is not annotated by
- * this annotation or the annotation is not accessible.
- */
- String[] getConstructorPropertiesValue(Constructor<?> ctr);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaIOAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,34 +0,0 @@
-/*
- * Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.Console;
-import java.nio.charset.Charset;
-
-public interface JavaIOAccess {
- public Console console();
- public Charset charset();
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaIOFileDescriptorAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-/*
- * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package jdk.internal.misc;
-
-import java.io.FileDescriptor;
-import java.io.IOException;
-
-import jdk.internal.ref.PhantomCleanable;
-
-/*
- * @author Chris Hegarty
- */
-
-public interface JavaIOFileDescriptorAccess {
- public void set(FileDescriptor fdo, int fd);
- public int get(FileDescriptor fdo);
- public void setAppend(FileDescriptor fdo, boolean append);
- public boolean getAppend(FileDescriptor fdo);
- public void close(FileDescriptor fdo) throws IOException;
- public void registerCleanup(FileDescriptor fdo);
- public void registerCleanup(FileDescriptor fdo, PhantomCleanable<FileDescriptor> cleanable);
- public void unregisterCleanup(FileDescriptor fdo);
-
- // Only valid on Windows
- public void setHandle(FileDescriptor fdo, long handle);
- public long getHandle(FileDescriptor fdo);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaIOFilePermissionAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package jdk.internal.misc;
-
-import java.io.FilePermission;
-
-public interface JavaIOFilePermissionAccess {
-
- /**
- * Returns a new FilePermission plus an alternative path.
- *
- * @param input the input
- * @return the new FilePermission plus the alt path (as npath2)
- * or the input itself if no alt path is available.
- */
- FilePermission newPermPlusAltPath(FilePermission input);
-
- /**
- * Returns a new FilePermission using an alternative path.
- *
- * @param input the input
- * @return the new FilePermission using the alt path (as npath)
- * or null if no alt path is available
- */
- FilePermission newPermUsingAltPath(FilePermission input);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaIORandomAccessFileAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.File;
-import java.io.IOException;
-import java.io.RandomAccessFile;
-
-public interface JavaIORandomAccessFileAccess {
- public RandomAccessFile openAndDelete(File file, String mode)
- throws IOException;
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaLangAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,314 +0,0 @@
-/*
- * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.lang.annotation.Annotation;
-import java.lang.module.ModuleDescriptor;
-import java.lang.reflect.Executable;
-import java.lang.reflect.Method;
-import java.net.URI;
-import java.nio.charset.CharacterCodingException;
-import java.nio.charset.Charset;
-import java.security.AccessControlContext;
-import java.security.ProtectionDomain;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.stream.Stream;
-
-import jdk.internal.module.ServicesCatalog;
-import jdk.internal.reflect.ConstantPool;
-import sun.reflect.annotation.AnnotationType;
-import sun.nio.ch.Interruptible;
-
-public interface JavaLangAccess {
-
- /**
- * Returns the list of {@code Method} objects for the declared public
- * methods of this class or interface that have the specified method name
- * and parameter types.
- */
- List<Method> getDeclaredPublicMethods(Class<?> klass, String name, Class<?>... parameterTypes);
-
- /**
- * Return the constant pool for a class.
- */
- ConstantPool getConstantPool(Class<?> klass);
-
- /**
- * Compare-And-Set the AnnotationType instance corresponding to this class.
- * (This method only applies to annotation types.)
- */
- boolean casAnnotationType(Class<?> klass, AnnotationType oldType, AnnotationType newType);
-
- /**
- * Get the AnnotationType instance corresponding to this class.
- * (This method only applies to annotation types.)
- */
- AnnotationType getAnnotationType(Class<?> klass);
-
- /**
- * Get the declared annotations for a given class, indexed by their types.
- */
- Map<Class<? extends Annotation>, Annotation> getDeclaredAnnotationMap(Class<?> klass);
-
- /**
- * Get the array of bytes that is the class-file representation
- * of this Class' annotations.
- */
- byte[] getRawClassAnnotations(Class<?> klass);
-
- /**
- * Get the array of bytes that is the class-file representation
- * of this Class' type annotations.
- */
- byte[] getRawClassTypeAnnotations(Class<?> klass);
-
- /**
- * Get the array of bytes that is the class-file representation
- * of this Executable's type annotations.
- */
- byte[] getRawExecutableTypeAnnotations(Executable executable);
-
- /**
- * Returns the elements of an enum class or null if the
- * Class object does not represent an enum type;
- * the result is uncloned, cached, and shared by all callers.
- */
- <E extends Enum<E>> E[] getEnumConstantsShared(Class<E> klass);
-
- /**
- * Set current thread's blocker field.
- */
- void blockedOn(Interruptible b);
-
- /**
- * Registers a shutdown hook.
- *
- * It is expected that this method with registerShutdownInProgress=true
- * is only used to register DeleteOnExitHook since the first file
- * may be added to the delete on exit list by the application shutdown
- * hooks.
- *
- * @param slot the slot in the shutdown hook array, whose element
- * will be invoked in order during shutdown
- * @param registerShutdownInProgress true to allow the hook
- * to be registered even if the shutdown is in progress.
- * @param hook the hook to be registered
- *
- * @throws IllegalStateException if shutdown is in progress and
- * the slot is not valid to register.
- */
- void registerShutdownHook(int slot, boolean registerShutdownInProgress, Runnable hook);
-
- /**
- * Returns a new Thread with the given Runnable and an
- * inherited AccessControlContext.
- */
- Thread newThreadWithAcc(Runnable target, AccessControlContext acc);
-
- /**
- * Invokes the finalize method of the given object.
- */
- void invokeFinalize(Object o) throws Throwable;
-
- /**
- * Returns the ConcurrentHashMap used as a storage for ClassLoaderValue(s)
- * associated with the given class loader, creating it if it doesn't already exist.
- */
- ConcurrentHashMap<?, ?> createOrGetClassLoaderValueMap(ClassLoader cl);
-
- /**
- * Defines a class with the given name to a class loader.
- */
- Class<?> defineClass(ClassLoader cl, String name, byte[] b, ProtectionDomain pd, String source);
-
- /**
- * Returns a class loaded by the bootstrap class loader.
- */
- Class<?> findBootstrapClassOrNull(ClassLoader cl, String name);
-
- /**
- * Define a Package of the given name and module by the given class loader.
- */
- Package definePackage(ClassLoader cl, String name, Module module);
-
- /**
- * Invokes Long.fastUUID
- */
- String fastUUID(long lsb, long msb);
-
- /**
- * Record the non-exported packages of the modules in the given layer
- */
- void addNonExportedPackages(ModuleLayer layer);
-
- /**
- * Invalidate package access cache
- */
- void invalidatePackageAccessCache();
-
- /**
- * Defines a new module to the Java virtual machine. The module
- * is defined to the given class loader.
- *
- * The URI is for information purposes only, it can be {@code null}.
- */
- Module defineModule(ClassLoader loader, ModuleDescriptor descriptor, URI uri);
-
- /**
- * Defines the unnamed module for the given class loader.
- */
- Module defineUnnamedModule(ClassLoader loader);
-
- /**
- * Updates the readability so that module m1 reads m2. The new read edge
- * does not result in a strong reference to m2 (m2 can be GC'ed).
- *
- * This method is the same as m1.addReads(m2) but without a permission check.
- */
- void addReads(Module m1, Module m2);
-
- /**
- * Updates module m to read all unnamed modules.
- */
- void addReadsAllUnnamed(Module m);
-
- /**
- * Updates module m1 to export a package to module m2. The export does
- * not result in a strong reference to m2 (m2 can be GC'ed).
- */
- void addExports(Module m1, String pkg, Module m2);
-
- /**
- * Updates a module m to export a package to all unnamed modules.
- */
- void addExportsToAllUnnamed(Module m, String pkg);
-
- /**
- * Updates module m1 to open a package to module m2. Opening the
- * package does not result in a strong reference to m2 (m2 can be GC'ed).
- */
- void addOpens(Module m1, String pkg, Module m2);
-
- /**
- * Updates module m to open a package to all unnamed modules.
- */
- void addOpensToAllUnnamed(Module m, String pkg);
-
- /**
- * Updates module m to open all packages returned by the given iterator.
- */
- void addOpensToAllUnnamed(Module m, Iterator<String> packages);
-
- /**
- * Updates module m to use a service.
- */
- void addUses(Module m, Class<?> service);
-
- /**
- * Returns true if module m reflectively exports a package to other
- */
- boolean isReflectivelyExported(Module module, String pn, Module other);
-
- /**
- * Returns true if module m reflectively opens a package to other
- */
- boolean isReflectivelyOpened(Module module, String pn, Module other);
-
- /**
- * Returns the ServicesCatalog for the given Layer.
- */
- ServicesCatalog getServicesCatalog(ModuleLayer layer);
-
- /**
- * Returns an ordered stream of layers. The first element is the
- * given layer, the remaining elements are its parents, in DFS order.
- */
- Stream<ModuleLayer> layers(ModuleLayer layer);
-
- /**
- * Returns a stream of the layers that have modules defined to the
- * given class loader.
- */
- Stream<ModuleLayer> layers(ClassLoader loader);
-
- /**
- * Constructs a new {@code String} by decoding the specified subarray of
- * bytes using the specified {@linkplain java.nio.charset.Charset charset}.
- *
- * The caller of this method shall relinquish and transfer the ownership of
- * the byte array to the callee since the later will not make a copy.
- *
- * @param bytes the byte array source
- * @param cs the Charset
- * @return the newly created string
- * @throws CharacterCodingException for malformed or unmappable bytes
- */
- String newStringNoRepl(byte[] bytes, Charset cs) throws CharacterCodingException;
-
- /**
- * Encode the given string into a sequence of bytes using the specified Charset.
- *
- * This method avoids copying the String's internal representation if the input
- * is ASCII.
- *
- * This method throws CharacterCodingException instead of replacing when
- * malformed input or unmappable characters are encountered.
- *
- * @param s the string to encode
- * @param cs the charset
- * @return the encoded bytes
- * @throws CharacterCodingException for malformed input or unmappable characters
- */
- byte[] getBytesNoRepl(String s, Charset cs) throws CharacterCodingException;
-
- /**
- * Returns a new string by decoding from the given utf8 bytes array.
- *
- * @param off the index of the first byte to decode
- * @param len the number of bytes to decode
- * @return the newly created string
- * @throws IllegalArgumentException for malformed or unmappable bytes.
- */
- String newStringUTF8NoRepl(byte[] bytes, int off, int len);
-
- /**
- * Encode the given string into a sequence of bytes using utf8.
- *
- * @param s the string to encode
- * @return the encoded bytes in utf8
- * @throws IllegalArgumentException for malformed surrogates
- */
- byte[] getBytesUTF8NoRepl(String s);
-
- /**
- * Set the cause of Throwable
- * @param cause set t's cause to new value
- */
- void setCause(Throwable t, Throwable cause);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaLangInvokeAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,109 +0,0 @@
-/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.lang.invoke.MethodType;
-import java.util.Map;
-
-public interface JavaLangInvokeAccess {
- /**
- * Create a new MemberName instance. Used by {@code StackFrameInfo}.
- */
- Object newMemberName();
-
- /**
- * Returns the name for the given MemberName. Used by {@code StackFrameInfo}.
- */
- String getName(Object mname);
-
- /**
- * Returns the {@code MethodType} for the given MemberName.
- * Used by {@code StackFrameInfo}.
- */
- MethodType getMethodType(Object mname);
-
- /**
- * Returns the descriptor for the given MemberName.
- * Used by {@code StackFrameInfo}.
- */
- String getMethodDescriptor(Object mname);
-
- /**
- * Returns {@code true} if the given MemberName is a native method.
- * Used by {@code StackFrameInfo}.
- */
- boolean isNative(Object mname);
-
- /**
- * Returns the declaring class for the given MemberName.
- * Used by {@code StackFrameInfo}.
- */
- Class<?> getDeclaringClass(Object mname);
-
- /**
- * Returns a {@code byte[]} representation of a class implementing
- * DirectMethodHandle of each pairwise combination of {@code MethodType} and
- * an {@code int} representing method type. Used by
- * GenerateJLIClassesPlugin to generate such a class during the jlink phase.
- */
- byte[] generateDirectMethodHandleHolderClassBytes(String className,
- MethodType[] methodTypes, int[] types);
-
- /**
- * Returns a {@code byte[]} representation of a class implementing
- * DelegatingMethodHandles of each {@code MethodType} kind in the
- * {@code methodTypes} argument. Used by GenerateJLIClassesPlugin to
- * generate such a class during the jlink phase.
- */
- byte[] generateDelegatingMethodHandleHolderClassBytes(String className,
- MethodType[] methodTypes);
-
- /**
- * Returns a {@code byte[]} representation of {@code BoundMethodHandle}
- * species class implementing the signature defined by {@code types}. Used
- * by GenerateJLIClassesPlugin to enable generation of such classes during
- * the jlink phase. Should do some added validation since this string may be
- * user provided.
- */
- Map.Entry<String, byte[]> generateConcreteBMHClassBytes(
- final String types);
-
- /**
- * Returns a {@code byte[]} representation of a class implementing
- * the zero and identity forms of all {@code LambdaForm.BasicType}s.
- */
- byte[] generateBasicFormsClassBytes(final String className);
-
- /**
- * Returns a {@code byte[]} representation of a class implementing
- * the invoker forms for the set of supplied {@code invokerMethodTypes}
- * and {@code callSiteMethodTypes}.
- */
- byte[] generateInvokersHolderClassBytes(String className,
- MethodType[] invokerMethodTypes,
- MethodType[] callSiteMethodTypes);
-
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaLangModuleAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,140 +0,0 @@
-/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.PrintStream;
-import java.lang.module.Configuration;
-import java.lang.module.ModuleDescriptor;
-import java.lang.module.ModuleDescriptor.Exports;
-import java.lang.module.ModuleDescriptor.Opens;
-import java.lang.module.ModuleDescriptor.Requires;
-import java.lang.module.ModuleDescriptor.Provides;
-import java.lang.module.ModuleDescriptor.Version;
-import java.lang.module.ModuleFinder;
-import java.util.Collection;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Provides access to non-public methods in java.lang.module.
- */
-
-public interface JavaLangModuleAccess {
-
- /**
- * Creates a builder for building a module with the given module name.
- *
- * @param strict
- * Indicates whether module names are checked or not
- */
- ModuleDescriptor.Builder newModuleBuilder(String mn,
- boolean strict,
- Set<ModuleDescriptor.Modifier> ms);
-
- /**
- * Returns a snapshot of the packages in the module.
- */
- Set<String> packages(ModuleDescriptor.Builder builder);
-
- /**
- * Adds a dependence on a module with the given (possibly un-parsable)
- * version string.
- */
- void requires(ModuleDescriptor.Builder builder,
- Set<Requires.Modifier> ms,
- String mn,
- String rawCompiledVersion);
-
- /**
- * Returns a {@code ModuleDescriptor.Requires} of the given modifiers
- * and module name.
- */
- Requires newRequires(Set<Requires.Modifier> ms, String mn, Version v);
-
- /**
- * Returns an unqualified {@code ModuleDescriptor.Exports}
- * of the given modifiers and package name source.
- */
- Exports newExports(Set<Exports.Modifier> ms,
- String source);
-
- /**
- * Returns a qualified {@code ModuleDescriptor.Exports}
- * of the given modifiers, package name source and targets.
- */
- Exports newExports(Set<Exports.Modifier> ms,
- String source,
- Set<String> targets);
-
- /**
- * Returns an unqualified {@code ModuleDescriptor.Opens}
- * of the given modifiers and package name source.
- */
- Opens newOpens(Set<Opens.Modifier> ms, String source);
-
- /**
- * Returns a qualified {@code ModuleDescriptor.Opens}
- * of the given modifiers, package name source and targets.
- */
- Opens newOpens(Set<Opens.Modifier> ms, String source, Set<String> targets);
-
- /**
- * Returns a {@code ModuleDescriptor.Provides}
- * of the given service name and providers.
- */
- Provides newProvides(String service, List<String> providers);
-
- /**
- * Returns a new {@code ModuleDescriptor} instance.
- */
- ModuleDescriptor newModuleDescriptor(String name,
- Version version,
- Set<ModuleDescriptor.Modifier> ms,
- Set<Requires> requires,
- Set<Exports> exports,
- Set<Opens> opens,
- Set<String> uses,
- Set<Provides> provides,
- Set<String> packages,
- String mainClass,
- int hashCode);
-
- /**
- * Resolves a collection of root modules, with service binding
- * and the empty configuration as the parent.
- */
- Configuration resolveAndBind(ModuleFinder finder,
- Collection<String> roots,
- PrintStream traceOutput);
-
- /**
- * Creates a configuration from a pre-generated readability graph.
- */
- Configuration newConfiguration(ModuleFinder finder,
- Map<String, Set<String>> graph);
-
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaLangRefAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,46 +0,0 @@
-/*
- * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-public interface JavaLangRefAccess {
-
- /**
- * Wait for progress in {@link java.lang.ref.Reference}
- * processing. If there aren't any pending {@link
- * java.lang.ref.Reference}s, return immediately.
- *
- * @return {@code true} if there were any pending
- * {@link java.lang.ref.Reference}s, {@code false} otherwise.
- */
- boolean waitForReferenceProcessing() throws InterruptedException;
-
- /**
- * Runs the finalization methods of any objects pending finalization.
- *
- * Invoked by Runtime.runFinalization()
- */
- void runFinalization();
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetHttpCookieAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
-/*
- * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.net.HttpCookie;
-import java.util.List;
-
-public interface JavaNetHttpCookieAccess {
- /*
- * Constructs cookies from Set-Cookie or Set-Cookie2 header string,
- * retaining the original header String in the cookie itself.
- */
- public List<HttpCookie> parse(String header);
-
- /*
- * Returns the original header this cookie was constructed from, if it was
- * constructed by parsing a header, otherwise null.
- */
- public String header(HttpCookie cookie);
-}
-
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetInetAddressAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,46 +0,0 @@
-/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.net.InetAddress;
-import java.net.UnknownHostException;
-
-public interface JavaNetInetAddressAccess {
- /**
- * Return the original application specified hostname of
- * the given InetAddress object.
- */
- String getOriginalHostName(InetAddress ia);
-
- /**
- * Get the InetAddress of the provided host. If an InetAddress is provided
- * then it will be the default address returned for all calls to either
- * form of getByName. This is required to maintain consistency when
- * caching addresses and hostnames.
- */
- InetAddress getByName(String hostName, InetAddress hostAddress)
- throws UnknownHostException;
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetSocketAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,41 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.net.ServerSocket;
-import java.net.SocketImpl;
-
-public interface JavaNetSocketAccess {
- /**
- * Creates a ServerSocket associated with the given SocketImpl.
- */
- ServerSocket newServerSocket(SocketImpl impl);
-
- /*
- * Constructs a SocketImpl instance of the given class.
- */
- SocketImpl newSocketImpl(Class<? extends SocketImpl> implClass);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetURLAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package jdk.internal.misc;
-
-import java.net.URL;
-import java.net.URLStreamHandler;
-
-public interface JavaNetURLAccess {
- URLStreamHandler getHandler(URL u);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetURLClassLoaderAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.net.URLClassLoader;
-import java.security.AccessControlContext;
-
-public interface JavaNetURLClassLoaderAccess {
- AccessControlContext getAccessControlContext(URLClassLoader u);;
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNetUriAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-/*
- * Copyright (c) 2006, 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.net.URI;
-
-public interface JavaNetUriAccess {
- /**
- * Create a URI of pre-validated scheme and path.
- */
- URI create(String scheme, String path);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaNioAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.nio.Buffer;
-import java.nio.ByteBuffer;
-
-public interface JavaNioAccess {
- /**
- * Provides access to information on buffer usage.
- */
- interface BufferPool {
- String getName();
- long getCount();
- long getTotalCapacity();
- long getMemoryUsed();
- }
- BufferPool getDirectBufferPool();
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaObjectInputFilterAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.ObjectInputFilter;
-
-/**
- * Access to the alternative ObjectInputFilter.Config.createFilter2 for RMI.
- */
-public interface JavaObjectInputFilterAccess {
- /**
- * Creates a filter from the pattern.
- */
- ObjectInputFilter createFilter2(String pattern);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaObjectInputStreamAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.InvalidClassException;
-import java.io.ObjectInputStream;
-
-/**
- * Interface to specify methods for accessing {@code ObjectInputStream}.
- */
-@FunctionalInterface
-public interface JavaObjectInputStreamAccess {
- void checkArray(ObjectInputStream ois, Class<?> arrayType, int arrayLength)
- throws InvalidClassException;
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaSecurityAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,53 +0,0 @@
-/*
- * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.security.AccessControlContext;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-import java.security.ProtectionDomain;
-
-public interface JavaSecurityAccess {
-
- <T> T doIntersectionPrivilege(PrivilegedAction<T> action,
- AccessControlContext stack,
- AccessControlContext context);
-
- <T> T doIntersectionPrivilege(PrivilegedAction<T> action,
- AccessControlContext context);
-
- ProtectionDomain[] getProtectDomains(AccessControlContext context);
-
- interface ProtectionDomainCache {
- void put(ProtectionDomain pd, PermissionCollection pc);
- PermissionCollection get(ProtectionDomain pd);
- }
-
- /**
- * Returns the ProtectionDomainCache.
- */
- ProtectionDomainCache getProtectionDomainCache();
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaUtilJarAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.IOException;
-import java.net.URL;
-import java.security.CodeSource;
-import java.util.Enumeration;
-import java.util.List;
-import java.util.jar.Attributes;
-import java.util.jar.JarEntry;
-import java.util.jar.JarFile;
-import java.util.jar.Manifest;
-
-public interface JavaUtilJarAccess {
- public boolean jarFileHasClassPathAttribute(JarFile jar) throws IOException;
- public CodeSource[] getCodeSources(JarFile jar, URL url);
- public CodeSource getCodeSource(JarFile jar, URL url, String name);
- public Enumeration<String> entryNames(JarFile jar, CodeSource[] cs);
- public Enumeration<JarEntry> entries2(JarFile jar);
- public void setEagerValidation(JarFile jar, boolean eager);
- public List<Object> getManifestDigests(JarFile jar);
- public Attributes getTrustedAttributes(Manifest man, String name);
- public void ensureInitialization(JarFile jar);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaUtilResourceBundleAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.util.Locale;
-import java.util.ResourceBundle;
-
-/**
- * Provides access to non-public methods in java.util.ResourceBundle.
- */
-public interface JavaUtilResourceBundleAccess {
- /**
- * Sets the bundle's parent to the given parent.
- */
- void setParent(ResourceBundle bundle, ResourceBundle parent);
-
- /**
- * Returns the parent of the given bundle or null if the bundle has no parent.
- */
- ResourceBundle getParent(ResourceBundle bundle);
-
- /**
- * Sets the bundle's locale to the given locale.
- */
- void setLocale(ResourceBundle bundle, Locale locale);
-
- /**
- * Sets the bundle's base name to the given name.
- */
- void setName(ResourceBundle bundle, String name);
-
- /**
- * Returns a {@code ResourceBundle} of the given baseName and locale
- * loaded on behalf of the given module with no caller module
- * access check.
- */
- ResourceBundle getBundle(String baseName, Locale locale, Module module);
-
- /**
- * Instantiates a {@code ResourceBundle} of the given bundle class.
- */
- ResourceBundle newResourceBundle(Class<? extends ResourceBundle> bundleClass);
-}
--- a/src/java.base/share/classes/jdk/internal/misc/JavaUtilZipFileAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import java.io.IOException;
-import java.util.Enumeration;
-import java.util.function.Function;
-import java.util.jar.JarEntry;
-import java.util.stream.Stream;
-import java.util.zip.ZipFile;
-
-public interface JavaUtilZipFileAccess {
- public boolean startsWithLocHeader(ZipFile zip);
- public String[] getMetaInfEntryNames(ZipFile zip);
- public JarEntry getEntry(ZipFile zip, String name, Function<String, JarEntry> func);
- public Enumeration<JarEntry> entries(ZipFile zip, Function<String, JarEntry> func);
- public Stream<JarEntry> stream(ZipFile zip, Function<String, JarEntry> func);
- public Stream<String> entryNameStream(ZipFile zip);
-}
-
--- a/src/java.base/share/classes/jdk/internal/misc/JavaxCryptoSealedObjectAccess.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-/*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package jdk.internal.misc;
-
-import javax.crypto.BadPaddingException;
-import javax.crypto.Cipher;
-import javax.crypto.IllegalBlockSizeException;
-import javax.crypto.SealedObject;
-import java.io.IOException;
-import java.io.ObjectInputStream;
-
-public interface JavaxCryptoSealedObjectAccess {
- ObjectInputStream getExtObjectInputStream(
- SealedObject sealed, Cipher cipher)
- throws BadPaddingException, IllegalBlockSizeException, IOException;
-}
--- a/src/java.base/share/classes/jdk/internal/misc/SharedSecrets.java Tue Nov 06 17:28:14 2018 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,339 +0,0 @@
-/*
- * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package jdk.internal.misc;
-
-import javax.crypto.SealedObject;
-import java.io.ObjectInputFilter;
-import java.lang.module.ModuleDescriptor;
-import java.util.ResourceBundle;
-import java.util.jar.JarFile;
-import java.io.Console;
-import java.io.FileDescriptor;
-import java.io.FilePermission;
-import java.io.ObjectInputStream;
-import java.io.RandomAccessFile;
-import java.security.ProtectionDomain;
-
-/** A repository of "shared secrets", which are a mechanism for
- calling implementation-private methods in another package without
- using reflection. A package-private class implements a public
- interface and provides the ability to call package-private methods
- within that package; the object implementing that interface is
- provided through a third package to which access is restricted.
- This framework avoids the primary disadvantage of using reflection
- for this purpose, namely the loss of compile-time checking. */
-
-public class SharedSecrets {
- private static final Unsafe unsafe = Unsafe.getUnsafe();
- private static JavaUtilJarAccess javaUtilJarAccess;
- private static JavaLangAccess javaLangAccess;
- private static JavaLangModuleAccess javaLangModuleAccess;
- private static JavaLangInvokeAccess javaLangInvokeAccess;
- private static JavaLangRefAccess javaLangRefAccess;
- private static JavaIOAccess javaIOAccess;
- private static JavaNetInetAddressAccess javaNetInetAddressAccess;
- private static JavaNetHttpCookieAccess javaNetHttpCookieAccess;
- private static JavaNetSocketAccess javaNetSocketAccess;
- private static JavaNetUriAccess javaNetUriAccess;
- private static JavaNetURLAccess javaNetURLAccess;
- private static JavaNetURLClassLoaderAccess javaNetURLClassLoaderAccess;
- private static JavaNioAccess javaNioAccess;
- private static JavaIOFileDescriptorAccess javaIOFileDescriptorAccess;
- private static JavaIOFilePermissionAccess javaIOFilePermissionAccess;
- private static JavaSecurityAccess javaSecurityAccess;
- private static JavaUtilZipFileAccess javaUtilZipFileAccess;
- private static JavaUtilResourceBundleAccess javaUtilResourceBundleAccess;
- private static JavaAWTAccess javaAWTAccess;
- private static JavaAWTFontAccess javaAWTFontAccess;
- private static JavaBeansAccess javaBeansAccess;
- private static JavaObjectInputStreamAccess javaObjectInputStreamAccess;
- private static JavaObjectInputFilterAccess javaObjectInputFilterAccess;
- private static JavaIORandomAccessFileAccess javaIORandomAccessFileAccess;
- private static JavaxCryptoSealedObjectAccess javaxCryptoSealedObjectAccess;
-
- public static JavaUtilJarAccess javaUtilJarAccess() {
- if (javaUtilJarAccess == null) {
- // Ensure JarFile is initialized; we know that that class
- // provides the shared secret
- unsafe.ensureClassInitialized(JarFile.class);
- }
- return javaUtilJarAccess;
- }
-
- public static void setJavaUtilJarAccess(JavaUtilJarAccess access) {
- javaUtilJarAccess = access;
- }
-
- public static void setJavaLangAccess(JavaLangAccess jla) {
- javaLangAccess = jla;
- }
-
- public static JavaLangAccess getJavaLangAccess() {
- return javaLangAccess;
- }
-
- public static void setJavaLangInvokeAccess(JavaLangInvokeAccess jlia) {
- javaLangInvokeAccess = jlia;
- }
-
- public static JavaLangInvokeAccess getJavaLangInvokeAccess() {
- if (javaLangInvokeAccess == null) {
- try {
- Class<?> c = Class.forName("java.lang.invoke.MethodHandleImpl");
- unsafe.ensureClassInitialized(c);
- } catch (ClassNotFoundException e) {};
- }
- return javaLangInvokeAccess;
- }
-
- public static void setJavaLangModuleAccess(JavaLangModuleAccess jlrma) {
- javaLangModuleAccess = jlrma;
- }
-
- public static JavaLangModuleAccess getJavaLangModuleAccess() {
- if (javaLangModuleAccess == null) {
- unsafe.ensureClassInitialized(ModuleDescriptor.class);
- }
- return javaLangModuleAccess;
- }
-
- public static void setJavaLangRefAccess(JavaLangRefAccess jlra) {
- javaLangRefAccess = jlra;
- }
-
- public static JavaLangRefAccess getJavaLangRefAccess() {
- return javaLangRefAccess;
- }
-
- public static void setJavaNetUriAccess(JavaNetUriAccess jnua) {
- javaNetUriAccess = jnua;
- }
-
- public static JavaNetUriAccess getJavaNetUriAccess() {
- if (javaNetUriAccess == null)
- unsafe.ensureClassInitialized(java.net.URI.class);
- return javaNetUriAccess;
- }
-
- public static void setJavaNetURLAccess(JavaNetURLAccess jnua) {
- javaNetURLAccess = jnua;
- }
-
- public static JavaNetURLAccess getJavaNetURLAccess() {
- if (javaNetURLAccess == null)
- unsafe.ensureClassInitialized(java.net.URL.class);
- return javaNetURLAccess;
- }
-
- public static void setJavaNetURLClassLoaderAccess(JavaNetURLClassLoaderAccess jnua) {
- javaNetURLClassLoaderAccess = jnua;
- }
-
- public static JavaNetURLClassLoaderAccess getJavaNetURLClassLoaderAccess() {
- if (javaNetURLClassLoaderAccess == null)
- unsafe.ensureClassInitialized(java.net.URLClassLoader.class);
- return javaNetURLClassLoaderAccess;
- }
-
- public static void setJavaNetInetAddressAccess(JavaNetInetAddressAccess jna) {
- javaNetInetAddressAccess = jna;
- }
-
- public static JavaNetInetAddressAccess getJavaNetInetAddressAccess() {
- if (javaNetInetAddressAccess == null)
- unsafe.ensureClassInitialized(java.net.InetAddress.class);
- return javaNetInetAddressAccess;
- }
-
- public static void setJavaNetHttpCookieAccess(JavaNetHttpCookieAccess a) {
- javaNetHttpCookieAccess = a;
- }
-
- public static JavaNetHttpCookieAccess getJavaNetHttpCookieAccess() {
- if (javaNetHttpCookieAccess == null)
- unsafe.ensureClassInitialized(java.net.HttpCookie.class);
- return javaNetHttpCookieAccess;
- }
-
- public static void setJavaNetSocketAccess(JavaNetSocketAccess jnsa) {
- javaNetSocketAccess = jnsa;
- }
-
- public static JavaNetSocketAccess getJavaNetSocketAccess() {
- if (javaNetSocketAccess == null)
- unsafe.ensureClassInitialized(java.net.ServerSocket.class);
- return javaNetSocketAccess;
- }
-
- public static void setJavaNioAccess(JavaNioAccess jna) {
- javaNioAccess = jna;
- }
-
- public static JavaNioAccess getJavaNioAccess() {
- if (javaNioAccess == null) {
- // Ensure java.nio.Buffer is initialized, which provides the
- // shared secret.
- unsafe.ensureClassInitialized(java.nio.Buffer.class);
- }
- return javaNioAccess;
- }
-
- public static void setJavaIOAccess(JavaIOAccess jia) {
- javaIOAccess = jia;
- }
-
- public static JavaIOAccess getJavaIOAccess() {
- if (javaIOAccess == null) {
- unsafe.ensureClassInitialized(Console.class);
- }
- return javaIOAccess;
- }
-
- public static void setJavaIOFileDescriptorAccess(JavaIOFileDescriptorAccess jiofda) {
- javaIOFileDescriptorAccess = jiofda;
- }
-
- public static JavaIOFilePermissionAccess getJavaIOFilePermissionAccess() {
- if (javaIOFilePermissionAccess == null)
- unsafe.ensureClassInitialized(FilePermission.class);
-
- return javaIOFilePermissionAccess;
- }
-
- public static void setJavaIOFilePermissionAccess(JavaIOFilePermissionAccess jiofpa) {
- javaIOFilePermissionAccess = jiofpa;
- }
-
- public static JavaIOFileDescriptorAccess getJavaIOFileDescriptorAccess() {
- if (javaIOFileDescriptorAccess == null)
- unsafe.ensureClassInitialized(FileDescriptor.class);
-
- return javaIOFileDescriptorAccess;
- }
-
- public static void setJavaSecurityAccess(JavaSecurityAccess jsa) {
- javaSecurityAccess = jsa;
- }
-
- public static JavaSecurityAccess getJavaSecurityAccess() {
- if (javaSecurityAccess == null) {
- unsafe.ensureClassInitialized(ProtectionDomain.class);
- }
- return javaSecurityAccess;
- }
-
- public static JavaUtilZipFileAccess getJavaUtilZipFileAccess() {
- if (javaUtilZipFileAccess == null)
- unsafe.ensureClassInitialized(java.util.zip.ZipFile.class);
- return javaUtilZipFileAccess;
- }
-
- public static void setJavaUtilZipFileAccess(JavaUtilZipFileAccess access) {
- javaUtilZipFileAccess = access;
- }
-
- public static void setJavaAWTAccess(JavaAWTAccess jaa) {
- javaAWTAccess = jaa;
- }
-
- public static JavaAWTAccess getJavaAWTAccess() {
- // this may return null in which case calling code needs to
- // provision for.
- return javaAWTAccess;
- }
-
- public static void setJavaAWTFontAccess(JavaAWTFontAccess jafa) {
- javaAWTFontAccess = jafa;
- }
-
- public static JavaAWTFontAccess getJavaAWTFontAccess() {
- // this may return null in which case calling code needs to
- // provision for.
- return javaAWTFontAccess;
- }
-
- public static JavaBeansAccess getJavaBeansAccess() {
- return javaBeansAccess;
- }
-
- public static void setJavaBeansAccess(JavaBeansAccess access) {
- javaBeansAccess = access;
- }
-
- public static JavaUtilResourceBundleAccess getJavaUtilResourceBundleAccess() {
- if (javaUtilResourceBundleAccess == null)
- unsafe.ensureClassInitialized(ResourceBundle.class);
- return javaUtilResourceBundleAccess;
- }
-
- public static void setJavaUtilResourceBundleAccess(JavaUtilResourceBundleAccess access) {
- javaUtilResourceBundleAccess = access;
- }
-
- public static JavaObjectInputStreamAccess getJavaObjectInputStreamAccess() {
- if (javaObjectInputStreamAccess == null) {
- unsafe.ensureClassInitialized(ObjectInputStream.class);
- }
- return javaObjectInputStreamAccess;
- }
-
- public static void setJavaObjectInputStreamAccess(JavaObjectInputStreamAccess access) {
- javaObjectInputStreamAccess = access;
- }
-
- public static JavaObjectInputFilterAccess getJavaObjectInputFilterAccess() {
- if (javaObjectInputFilterAccess == null) {
- unsafe.ensureClassInitialized(ObjectInputFilter.Config.class);
- }
- return javaObjectInputFilterAccess;
- }
-
- public static void setJavaObjectInputFilterAccess(JavaObjectInputFilterAccess access) {
- javaObjectInputFilterAccess = access;
- }
-
- public static void setJavaIORandomAccessFileAccess(JavaIORandomAccessFileAccess jirafa) {
- javaIORandomAccessFileAccess = jirafa;
- }
-
- public static JavaIORandomAccessFileAccess getJavaIORandomAccessFileAccess() {
- if (javaIORandomAccessFileAccess == null) {
- unsafe.ensureClassInitialized(RandomAccessFile.class);
- }
- return javaIORandomAccessFileAccess;
- }
-
- public static void setJavaxCryptoSealedObjectAccess(JavaxCryptoSealedObjectAccess jcsoa) {
- javaxCryptoSealedObjectAccess = jcsoa;
- }
-
- public static JavaxCryptoSealedObjectAccess getJavaxCryptoSealedObjectAccess() {
- if (javaxCryptoSealedObjectAccess == null) {
- unsafe.ensureClassInitialized(SealedObject.class);
- }
- return javaxCryptoSealedObjectAccess;
- }
-}
--- a/src/java.base/share/classes/jdk/internal/misc/Unsafe.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/misc/Unsafe.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,9 @@
package jdk.internal.misc;
import jdk.internal.HotSpotIntrinsicCandidate;
+import jdk.internal.ref.Cleaner;
import jdk.internal.vm.annotation.ForceInline;
+import sun.nio.ch.DirectBuffer;
import java.lang.reflect.Field;
import java.security.ProtectionDomain;
@@ -3718,6 +3720,29 @@
private native boolean isBigEndian0();
+ /**
+ * Invokes the given direct byte buffer's cleaner, if any.
+ *
+ * @param directBuffer a direct byte buffer
+ * @throws NullPointerException if {@code directBuffer} is null
+ * @throws IllegalArgumentException if {@code directBuffer} is non-direct,
+ * or is a {@link java.nio.Buffer#slice slice}, or is a
+ * {@link java.nio.Buffer#duplicate duplicate}
+ */
+ public void invokeCleaner(java.nio.ByteBuffer directBuffer) {
+ if (!directBuffer.isDirect())
+ throw new IllegalArgumentException("buffer is non-direct");
+
+ DirectBuffer db = (DirectBuffer) directBuffer;
+ if (db.attachment() != null)
+ throw new IllegalArgumentException("duplicate or slice");
+
+ Cleaner cleaner = db.cleaner();
+ if (cleaner != null) {
+ cleaner.clean();
+ }
+ }
+
// The following deprecated methods are used by JSR 166.
@Deprecated(since="12", forRemoval=true)
--- a/src/java.base/share/classes/jdk/internal/module/Builder.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/Builder.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -33,8 +33,8 @@
import java.util.List;
import java.util.Set;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
/**
* This builder is optimized for reconstituting the {@code ModuleDescriptor}s
--- a/src/java.base/share/classes/jdk/internal/module/IllegalAccessLogger.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/IllegalAccessLogger.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -44,8 +44,8 @@
import java.util.stream.Collectors;
import static java.util.Collections.*;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
/**
* Supports logging of access to members of exported and concealed packages
--- a/src/java.base/share/classes/jdk/internal/module/ModuleBootstrap.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/ModuleBootstrap.java Tue Nov 06 10:01:16 2018 -0800
@@ -51,10 +51,9 @@
import jdk.internal.loader.BootLoader;
import jdk.internal.loader.BuiltinClassLoader;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.VM;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.perf.PerfCounter;
/**
--- a/src/java.base/share/classes/jdk/internal/module/ModuleInfo.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/ModuleInfo.java Tue Nov 06 10:01:16 2018 -0800
@@ -47,8 +47,8 @@
import java.util.Set;
import java.util.function.Supplier;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
import static jdk.internal.module.ClassFileConstants.*;
--- a/src/java.base/share/classes/jdk/internal/module/ModulePatcher.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/ModulePatcher.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -54,8 +54,8 @@
import java.util.stream.Stream;
import jdk.internal.loader.Resource;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
import sun.net.www.ParseUtil;
--- a/src/java.base/share/classes/jdk/internal/module/Modules.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/Modules.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -43,8 +43,8 @@
import jdk.internal.loader.BootLoader;
import jdk.internal.loader.BuiltinClassLoader;
import jdk.internal.loader.ClassLoaders;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
/**
* A helper class for creating and updating modules. This class is intended to
--- a/src/java.base/share/classes/jdk/internal/module/SystemModuleFinders.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/module/SystemModuleFinders.java Tue Nov 06 10:01:16 2018 -0800
@@ -59,8 +59,8 @@
import jdk.internal.jimage.ImageLocation;
import jdk.internal.jimage.ImageReader;
import jdk.internal.jimage.ImageReaderFactory;
-import jdk.internal.misc.JavaNetUriAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetUriAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.util.StaticProperty;
import jdk.internal.module.ModuleHashes.HashSupplier;
--- a/src/java.base/share/classes/jdk/internal/reflect/ClassDefiner.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/jdk/internal/reflect/ClassDefiner.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,8 +28,8 @@
import java.security.AccessController;
import java.security.PrivilegedAction;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
/** Utility class which assists in calling defineClass() by
creating a new class loader which delegates to the one needed in
--- a/src/java.base/share/classes/module-info.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/module-info.java Tue Nov 06 10:01:16 2018 -0800
@@ -136,6 +136,14 @@
java.security.sasl;
exports jdk.internal to
jdk.jfr;
+ exports jdk.internal.access to
+ java.desktop,
+ java.logging,
+ java.management,
+ java.naming,
+ java.rmi,
+ jdk.jlink,
+ jdk.net;
exports jdk.internal.event to
jdk.jfr;
exports jdk.internal.jimage to
@@ -175,18 +183,15 @@
java.logging,
java.management,
java.naming,
+ java.net.http,
java.rmi,
java.security.jgss,
- java.sql,
java.xml,
jdk.attach,
jdk.charsets,
jdk.compiler,
- java.net.http,
jdk.jfr,
- jdk.jlink,
jdk.jshell,
- jdk.net,
jdk.scripting.nashorn,
jdk.scripting.nashorn.shell,
jdk.unsupported,
@@ -202,8 +207,7 @@
jdk.management.agent,
jdk.internal.jvmstat;
exports jdk.internal.ref to
- java.desktop,
- jdk.unsupported;
+ java.desktop;
exports jdk.internal.reflect to
java.logging,
java.sql,
@@ -244,12 +248,9 @@
java.management,
jdk.crypto.cryptoki,
jdk.net,
- jdk.sctp,
- jdk.unsupported;
+ jdk.sctp;
exports sun.nio.cs to
jdk.charsets;
- exports sun.nio.fs to
- jdk.unsupported;
exports sun.reflect.annotation to
jdk.compiler;
exports sun.reflect.generics.reflectiveObjects to
--- a/src/java.base/share/classes/sun/net/sdp/SdpSupport.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/net/sdp/SdpSupport.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,8 +29,8 @@
import java.io.FileDescriptor;
import java.security.AccessController;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
import sun.security.action.GetPropertyAction;
--- a/src/java.base/share/classes/sun/net/www/protocol/http/HttpURLConnection.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/net/www/protocol/http/HttpURLConnection.java Tue Nov 06 10:01:16 2018 -0800
@@ -65,8 +65,8 @@
import java.util.HashMap;
import java.util.Set;
import java.util.StringJoiner;
-import jdk.internal.misc.JavaNetHttpCookieAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetHttpCookieAccess;
+import jdk.internal.access.SharedSecrets;
import sun.net.*;
import sun.net.www.*;
import sun.net.www.http.HttpClient;
--- a/src/java.base/share/classes/sun/nio/ch/FileChannelImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/nio/ch/FileChannelImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -43,9 +43,9 @@
import java.nio.channels.SelectableChannel;
import java.nio.channels.WritableByteChannel;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.JavaNioAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.JavaNioAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.Cleaner;
import jdk.internal.ref.CleanerFactory;
--- a/src/java.base/share/classes/sun/reflect/annotation/AnnotationSupport.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/reflect/annotation/AnnotationSupport.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -35,8 +35,8 @@
import java.util.Map;
import java.util.Objects;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
import jdk.internal.reflect.ReflectionFactory;
public final class AnnotationSupport {
--- a/src/java.base/share/classes/sun/reflect/annotation/AnnotationType.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/reflect/annotation/AnnotationType.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,8 +30,8 @@
import java.util.*;
import java.security.AccessController;
import java.security.PrivilegedAction;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
/**
* Represents an annotation type at run time. Used to type-check annotations
--- a/src/java.base/share/classes/sun/reflect/annotation/TypeAnnotationParser.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/reflect/annotation/TypeAnnotationParser.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,8 +34,8 @@
import java.util.List;
import java.util.LinkedHashMap;
import java.util.Map;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaLangAccess;
import jdk.internal.reflect.ConstantPool;
import static sun.reflect.annotation.TypeAnnotation.*;
--- a/src/java.base/share/classes/sun/security/provider/PolicyFile.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/security/provider/PolicyFile.java Tue Nov 06 10:01:16 2018 -0800
@@ -41,9 +41,9 @@
import java.net.SocketPermission;
import java.net.NetPermission;
import java.util.concurrent.ConcurrentHashMap;
-import jdk.internal.misc.JavaSecurityAccess;
-import static jdk.internal.misc.JavaSecurityAccess.ProtectionDomainCache;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
+import static jdk.internal.access.JavaSecurityAccess.ProtectionDomainCache;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.util.StaticProperty;
import sun.security.util.*;
import sun.net.www.ParseUtil;
--- a/src/java.base/share/classes/sun/security/ssl/SSLSocketImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/security/ssl/SSLSocketImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -47,8 +47,8 @@
import javax.net.ssl.SSLServerSocket;
import javax.net.ssl.SSLSession;
import javax.net.ssl.SSLSocket;
-import jdk.internal.misc.JavaNetInetAddressAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetInetAddressAccess;
+import jdk.internal.access.SharedSecrets;
/**
* Implementation of an SSL socket.
@@ -1229,7 +1229,7 @@
// identification. Use the application original specified
// hostname or IP address instead.
- // Get the original hostname via jdk.internal.misc.SharedSecrets
+ // Get the original hostname via jdk.internal.access.SharedSecrets
InetAddress inetAddress = getInetAddress();
if (inetAddress == null) { // not connected
return;
--- a/src/java.base/share/classes/sun/security/util/FilePermCompat.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/security/util/FilePermCompat.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,7 +29,7 @@
import java.io.FilePermission;
import java.security.Permission;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* Take care of FilePermission compatibility after JDK-8164705.
--- a/src/java.base/share/classes/sun/security/util/Password.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/security/util/Password.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,7 +29,7 @@
import java.nio.*;
import java.nio.charset.*;
import java.util.Arrays;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* A utility class for reading passwords
--- a/src/java.base/share/classes/sun/text/bidi/BidiBase.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/text/bidi/BidiBase.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -52,8 +52,8 @@
import java.text.AttributedCharacterIterator;
import java.text.Bidi;
import java.util.Arrays;
-import jdk.internal.misc.JavaAWTFontAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTFontAccess;
+import jdk.internal.access.SharedSecrets;
import sun.text.normalizer.UBiDiProps;
import sun.text.normalizer.UCharacter;
import sun.text.normalizer.UTF16;
--- a/src/java.base/share/classes/sun/util/resources/Bundles.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/share/classes/sun/util/resources/Bundles.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -56,8 +56,8 @@
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
import java.util.spi.ResourceBundleProvider;
-import jdk.internal.misc.JavaUtilResourceBundleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaUtilResourceBundleAccess;
+import jdk.internal.access.SharedSecrets;
/**
*/
--- a/src/java.base/unix/classes/java/lang/ProcessImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/unix/classes/java/lang/ProcessImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -47,8 +47,8 @@
import java.security.PrivilegedActionException;
import java.security.PrivilegedExceptionAction;
import java.util.Properties;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.util.StaticProperty;
import sun.security.action.GetPropertyAction;
--- a/src/java.base/unix/classes/sun/nio/ch/FileDispatcherImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/unix/classes/sun/nio/ch/FileDispatcherImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -28,8 +28,8 @@
import java.io.FileDescriptor;
import java.io.IOException;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
class FileDispatcherImpl extends FileDispatcher {
--- a/src/java.base/unix/classes/sun/nio/fs/UnixChannelFactory.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/unix/classes/sun/nio/fs/UnixChannelFactory.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,8 +30,8 @@
import java.io.FileDescriptor;
import java.util.Set;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
import sun.nio.ch.FileChannelImpl;
import sun.nio.ch.ThreadPool;
import sun.nio.ch.SimpleAsynchronousFileChannelImpl;
--- a/src/java.base/windows/classes/java/lang/ProcessImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/java/lang/ProcessImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -43,8 +43,8 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.ref.CleanerFactory;
/* This class is for the exclusive use of ProcessBuilder.start() to
--- a/src/java.base/windows/classes/java/net/DualStackPlainDatagramSocketImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/java/net/DualStackPlainDatagramSocketImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,8 +25,8 @@
package java.net;
import java.io.IOException;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
/**
* This class defines the plain DatagramSocketImpl that is used on
--- a/src/java.base/windows/classes/java/net/PlainSocketImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/java/net/PlainSocketImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,10 +27,10 @@
import java.io.IOException;
import java.io.FileDescriptor;
import java.security.AccessController;
-import java.security.PrivilegedAction;
+
import sun.security.action.GetPropertyAction;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
/**
* On Windows system we simply delegate to native methods.
--- a/src/java.base/windows/classes/sun/nio/ch/FileDispatcherImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/sun/nio/ch/FileDispatcherImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,8 +27,8 @@
import java.io.FileDescriptor;
import java.io.IOException;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
import sun.security.action.GetPropertyAction;
import java.io.File;
import java.nio.CharBuffer;
--- a/src/java.base/windows/classes/sun/nio/ch/WindowsAsynchronousFileChannelImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/sun/nio/ch/WindowsAsynchronousFileChannelImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -31,8 +31,8 @@
import java.nio.BufferOverflowException;
import java.io.IOException;
import java.io.FileDescriptor;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
/**
* Windows implementation of AsynchronousFileChannel using overlapped I/O.
--- a/src/java.base/windows/classes/sun/nio/fs/WindowsChannelFactory.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.base/windows/classes/sun/nio/fs/WindowsChannelFactory.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,8 +34,8 @@
import java.nio.file.StandardOpenOption;
import java.util.Set;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
import sun.nio.ch.FileChannelImpl;
import sun.nio.ch.ThreadPool;
import sun.nio.ch.WindowsAsynchronousFileChannelImpl;
--- a/src/java.desktop/share/classes/com/sun/beans/decoder/DocumentHandler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/com/sun/beans/decoder/DocumentHandler.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -50,7 +50,7 @@
import org.xml.sax.SAXException;
import org.xml.sax.helpers.DefaultHandler;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* The main class to parse JavaBeans XML archive.
--- a/src/java.desktop/share/classes/java/awt/EventQueue.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/java/awt/EventQueue.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -47,8 +47,8 @@
import java.security.AccessControlContext;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaSecurityAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
/**
* {@code EventQueue} is a platform-independent class
--- a/src/java.desktop/share/classes/java/awt/font/JavaAWTFontAccessImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/java/awt/font/JavaAWTFontAccessImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,7 @@
package java.awt.font;
-import jdk.internal.misc.JavaAWTFontAccess;
+import jdk.internal.access.JavaAWTFontAccess;
class JavaAWTFontAccessImpl implements JavaAWTFontAccess {
--- a/src/java.desktop/share/classes/java/awt/font/NumericShaper.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/java/awt/font/NumericShaper.java Tue Nov 06 10:01:16 2018 -0800
@@ -31,7 +31,7 @@
import java.util.Comparator;
import java.util.EnumSet;
import java.util.Set;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* The {@code NumericShaper} class is used to convert Latin-1 (European)
--- a/src/java.desktop/share/classes/java/awt/font/TextAttribute.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/java/awt/font/TextAttribute.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -44,7 +44,7 @@
import java.text.AttributedCharacterIterator.Attribute;
import java.util.Map;
import java.util.HashMap;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/**
* The {@code TextAttribute} class defines attribute keys and
--- a/src/java.desktop/share/classes/java/beans/Introspector.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/java/beans/Introspector.java Tue Nov 06 10:01:16 2018 -0800
@@ -42,15 +42,14 @@
import java.util.Map;
import java.util.ArrayList;
-import java.util.Arrays;
import java.util.HashMap;
import java.util.Iterator;
import java.util.EventObject;
import java.util.List;
import java.util.TreeMap;
-import jdk.internal.misc.JavaBeansAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaBeansAccess;
+import jdk.internal.access.SharedSecrets;
import sun.reflect.misc.ReflectUtil;
/**
--- a/src/java.desktop/share/classes/javax/swing/RepaintManager.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/javax/swing/RepaintManager.java Tue Nov 06 10:01:16 2018 -0800
@@ -35,8 +35,8 @@
import java.util.concurrent.atomic.AtomicInteger;
import java.applet.*;
-import jdk.internal.misc.JavaSecurityAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
+import jdk.internal.access.SharedSecrets;
import sun.awt.AWTAccessor;
import sun.awt.AppContext;
import sun.awt.DisplayChangedListener;
--- a/src/java.desktop/share/classes/javax/swing/TransferHandler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/javax/swing/TransferHandler.java Tue Nov 06 10:01:16 2018 -0800
@@ -46,9 +46,9 @@
import java.security.PrivilegedAction;
import java.security.AccessControlContext;
-import java.security.ProtectionDomain;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaSecurityAccess;
+
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
import sun.awt.AWTAccessor;
--- a/src/java.desktop/share/classes/sun/awt/AppContext.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.desktop/share/classes/sun/awt/AppContext.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -44,8 +44,8 @@
import java.beans.PropertyChangeListener;
import java.lang.ref.SoftReference;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
import sun.util.logging.PlatformLogger;
import java.util.concurrent.locks.Condition;
import java.util.concurrent.locks.Lock;
--- a/src/java.logging/share/classes/java/util/logging/Level.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.logging/share/classes/java/util/logging/Level.java Tue Nov 06 10:01:16 2018 -0800
@@ -40,8 +40,8 @@
import java.util.ResourceBundle;
import java.util.function.Function;
import jdk.internal.loader.ClassLoaderValue;
-import jdk.internal.misc.JavaUtilResourceBundleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaUtilResourceBundleAccess;
+import jdk.internal.access.SharedSecrets;
/**
* The Level class defines a set of standard logging levels that
--- a/src/java.logging/share/classes/java/util/logging/LogManager.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.logging/share/classes/java/util/logging/LogManager.java Tue Nov 06 10:01:16 2018 -0800
@@ -39,8 +39,8 @@
import java.util.function.Predicate;
import java.util.stream.Collectors;
import java.util.stream.Stream;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
import sun.util.logging.internal.LoggingProviderImpl;
import static jdk.internal.logger.DefaultLoggerFinder.isSystem;
--- a/src/java.logging/share/classes/java/util/logging/Logger.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.logging/share/classes/java/util/logging/Logger.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -37,8 +37,8 @@
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.function.Supplier;
-import jdk.internal.misc.JavaUtilResourceBundleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaUtilResourceBundleAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
import static jdk.internal.logger.DefaultLoggerFinder.isSystem;
--- a/src/java.management/share/classes/com/sun/jmx/mbeanserver/JavaBeansAccessor.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.management/share/classes/com/sun/jmx/mbeanserver/JavaBeansAccessor.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,8 @@
import java.lang.reflect.Constructor;
import java.lang.reflect.Method;
-import jdk.internal.misc.JavaBeansAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaBeansAccess;
+import jdk.internal.access.SharedSecrets;
/**
* A centralized place for gaining access to java.beans related functionality -
--- a/src/java.management/share/classes/javax/management/modelmbean/RequiredModelMBean.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.management/share/classes/javax/management/modelmbean/RequiredModelMBean.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -80,8 +80,8 @@
import javax.management.RuntimeOperationsException;
import javax.management.ServiceNotFoundException;
import javax.management.loading.ClassLoaderRepository;
-import jdk.internal.misc.JavaSecurityAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaSecurityAccess;
+import jdk.internal.access.SharedSecrets;
import sun.reflect.misc.MethodUtil;
import sun.reflect.misc.ReflectUtil;
--- a/src/java.management/share/classes/javax/management/openmbean/TabularDataSupport.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.management/share/classes/javax/management/openmbean/TabularDataSupport.java Tue Nov 06 10:01:16 2018 -0800
@@ -45,7 +45,7 @@
import java.util.List;
import java.util.Map;
import java.util.Set;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
// jmx import
//
--- a/src/java.management/share/classes/sun/management/ManagementFactoryHelper.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.management/share/classes/sun/management/ManagementFactoryHelper.java Tue Nov 06 10:01:16 2018 -0800
@@ -39,8 +39,8 @@
import java.security.PrivilegedActionException;
import java.security.PrivilegedExceptionAction;
-import jdk.internal.misc.JavaNioAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNioAccess;
+import jdk.internal.access.SharedSecrets;
import java.util.ArrayList;
import java.util.List;
--- a/src/java.naming/share/classes/com/sun/jndi/ldap/VersionHelper.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.naming/share/classes/com/sun/jndi/ldap/VersionHelper.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,7 @@
package com.sun.jndi.ldap;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import java.net.MalformedURLException;
import java.net.URL;
--- a/src/java.rmi/share/classes/sun/rmi/registry/RegistryImpl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/java.rmi/share/classes/sun/rmi/registry/RegistryImpl.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -57,7 +57,7 @@
import java.security.ProtectionDomain;
import java.text.MessageFormat;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import sun.rmi.runtime.Log;
import sun.rmi.server.UnicastRef;
import sun.rmi.server.UnicastServerRef;
--- a/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -75,7 +75,8 @@
}
private static Object getConstantPoolForObject() {
- String miscPackage = Java8OrEarlier ? "sun.misc" : "jdk.internal.misc";
+ String miscPackage = Java8OrEarlier ? "sun.misc"
+ : (Java11OrEarlier ? "jdk.internal.misc" : "jdk.internal.access");
try {
Class<?> sharedSecretsClass = Class.forName(miscPackage + ".SharedSecrets");
Class<?> javaLangAccessClass = Class.forName(miscPackage + ".JavaLangAccess");
@@ -114,7 +115,10 @@
Object javaBaseModule = JLModule.fromClass(String.class);
Object cModule = JLModule.fromClass(c);
uncheckedAddExports(javaBaseModule, "jdk.internal.reflect", cModule);
- uncheckedAddExports(javaBaseModule, "jdk.internal.misc", cModule);
+ if (Java11OrEarlier)
+ uncheckedAddExports(javaBaseModule, "jdk.internal.misc", cModule);
+ else
+ uncheckedAddExports(javaBaseModule, "jdk.internal.access", cModule);
}
}
--- a/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -72,6 +72,7 @@
}
public static final boolean Java8OrEarlier = GraalServices.Java8OrEarlier;
+ public static final boolean Java11OrEarlier = GraalServices.Java11OrEarlier;
protected Method getMethod(String methodName) {
return getMethod(getClass(), methodName);
--- a/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/GenerateJLIClassesPlugin.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/GenerateJLIClassesPlugin.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,18 +30,16 @@
import java.io.InputStream;
import java.io.InputStreamReader;
import java.lang.invoke.MethodType;
-import java.lang.module.ModuleDescriptor;
import java.nio.file.Files;
import java.util.EnumSet;
import java.util.Map;
-import java.util.Optional;
import java.util.Set;
import java.util.TreeMap;
import java.util.TreeSet;
import java.util.stream.Collectors;
import java.util.stream.Stream;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaLangInvokeAccess;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.access.JavaLangInvokeAccess;
import jdk.tools.jlink.plugin.ResourcePoolEntry;
import jdk.tools.jlink.plugin.PluginException;
import jdk.tools.jlink.plugin.ResourcePool;
--- a/src/jdk.net/share/classes/jdk/net/ExtendedSocketOptions.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.net/share/classes/jdk/net/ExtendedSocketOptions.java Tue Nov 06 10:01:16 2018 -0800
@@ -33,8 +33,8 @@
import java.util.Collections;
import java.util.HashSet;
import java.util.Set;
-import jdk.internal.misc.JavaIOFileDescriptorAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaIOFileDescriptorAccess;
+import jdk.internal.access.SharedSecrets;
/**
* Defines extended socket options, beyond those defined in
--- a/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedCopyOption.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedCopyOption.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@
package com.sun.nio.file;
import java.nio.file.CopyOption;
-import sun.nio.fs.ExtendedOptions;
+import jdk.internal.misc.FileSystemOption;
/**
* Defines <em>extended</em> copy options supported on some platforms
@@ -40,9 +40,9 @@
* The copy may be interrupted by the {@link Thread#interrupt interrupt}
* method.
*/
- INTERRUPTIBLE(ExtendedOptions.INTERRUPTIBLE);
+ INTERRUPTIBLE(FileSystemOption.INTERRUPTIBLE);
- ExtendedCopyOption(ExtendedOptions.InternalOption<Void> option) {
+ ExtendedCopyOption(FileSystemOption<Void> option) {
option.register(this);
}
}
--- a/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedOpenOption.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedOpenOption.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@
package com.sun.nio.file;
import java.nio.file.OpenOption;
-import sun.nio.fs.ExtendedOptions;
+import jdk.internal.misc.FileSystemOption;
/**
* Defines <em>extended</em> open options supported on some platforms
@@ -39,15 +39,15 @@
/**
* Prevent operations on the file that request read access.
*/
- NOSHARE_READ(ExtendedOptions.NOSHARE_READ),
+ NOSHARE_READ(FileSystemOption.NOSHARE_READ),
/**
* Prevent operations on the file that request write access.
*/
- NOSHARE_WRITE(ExtendedOptions.NOSHARE_WRITE),
+ NOSHARE_WRITE(FileSystemOption.NOSHARE_WRITE),
/**
* Prevent operations on the file that request delete access.
*/
- NOSHARE_DELETE(ExtendedOptions.NOSHARE_DELETE),
+ NOSHARE_DELETE(FileSystemOption.NOSHARE_DELETE),
/**
* Requires that direct I/O be used for read or write access.
@@ -69,9 +69,9 @@
*
* @since 10
*/
- DIRECT(ExtendedOptions.DIRECT);
+ DIRECT(FileSystemOption.DIRECT);
- ExtendedOpenOption(ExtendedOptions.InternalOption<Void> option) {
+ ExtendedOpenOption(FileSystemOption<Void> option) {
option.register(this);
}
}
--- a/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.unsupported/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@
package com.sun.nio.file;
import java.nio.file.WatchEvent.Modifier;
-import sun.nio.fs.ExtendedOptions;
+import jdk.internal.misc.FileSystemOption;
/**
* Defines <em>extended</em> watch event modifiers supported on some platforms
@@ -40,9 +40,9 @@
/**
* Register a file tree instead of a single directory.
*/
- FILE_TREE(ExtendedOptions.FILE_TREE);
+ FILE_TREE(FileSystemOption.FILE_TREE);
- ExtendedWatchEventModifier(ExtendedOptions.InternalOption<Void> option) {
+ ExtendedWatchEventModifier(FileSystemOption<Void> option) {
option.register(this);
}
}
--- a/src/jdk.unsupported/share/classes/com/sun/nio/file/SensitivityWatchEventModifier.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.unsupported/share/classes/com/sun/nio/file/SensitivityWatchEventModifier.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@
package com.sun.nio.file;
import java.nio.file.WatchEvent.Modifier;
-import sun.nio.fs.ExtendedOptions;
+import jdk.internal.misc.FileSystemOption;
/**
* Defines the <em>sensitivity levels</em> when registering objects with a
@@ -39,15 +39,15 @@
/**
* High sensitivity.
*/
- HIGH(ExtendedOptions.SENSITIVITY_HIGH, 2),
+ HIGH(FileSystemOption.SENSITIVITY_HIGH, 2),
/**
* Medium sensitivity.
*/
- MEDIUM(ExtendedOptions.SENSITIVITY_MEDIUM, 10),
+ MEDIUM(FileSystemOption.SENSITIVITY_MEDIUM, 10),
/**
* Low sensitivity.
*/
- LOW(ExtendedOptions.SENSITIVITY_LOW, 30);
+ LOW(FileSystemOption.SENSITIVITY_LOW, 30);
/**
* Returns the sensitivity in seconds.
@@ -57,7 +57,7 @@
}
private final int sensitivity;
- private SensitivityWatchEventModifier(ExtendedOptions.InternalOption<Integer> option,
+ private SensitivityWatchEventModifier(FileSystemOption<Integer> option,
int sensitivity) {
this.sensitivity = sensitivity;
option.register(this, sensitivity);
--- a/src/jdk.unsupported/share/classes/sun/misc/Unsafe.java Tue Nov 06 17:28:14 2018 +0100
+++ b/src/jdk.unsupported/share/classes/sun/misc/Unsafe.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,10 +27,8 @@
import jdk.internal.vm.annotation.ForceInline;
import jdk.internal.misc.VM;
-import jdk.internal.ref.Cleaner;
import jdk.internal.reflect.CallerSensitive;
import jdk.internal.reflect.Reflection;
-import sun.nio.ch.DirectBuffer;
import java.lang.reflect.Field;
import java.util.Set;
@@ -1234,13 +1232,6 @@
if (!directBuffer.isDirect())
throw new IllegalArgumentException("buffer is non-direct");
- DirectBuffer db = (DirectBuffer)directBuffer;
- if (db.attachment() != null)
- throw new IllegalArgumentException("duplicate or slice");
-
- Cleaner cleaner = db.cleaner();
- if (cleaner != null) {
- cleaner.clean();
- }
+ theInternalUnsafe.invokeCleaner(directBuffer);
}
}
--- a/test/hotspot/jtreg/applications/ctw/modules/generate.bash Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/generate.bash Tue Nov 06 10:01:16 2018 -0800
@@ -1,6 +1,6 @@
#!/bin/bash
#
-# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
@@ -30,7 +30,7 @@
echo creating $file for $module...
cat > $file <<EOF
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -57,7 +57,8 @@
* @summary run CTW for all classes from $module module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules $module
--- a/test/hotspot/jtreg/applications/ctw/modules/java_base.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_base.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,8 @@
* @summary run CTW for some classes from java.base module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.base
--- a/test/hotspot/jtreg/applications/ctw/modules/java_base_2.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_base_2.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,8 @@
* @summary run CTW for some classes from java.base module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.base
--- a/test/hotspot/jtreg/applications/ctw/modules/java_compiler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_compiler.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.compiler module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.compiler
--- a/test/hotspot/jtreg/applications/ctw/modules/java_datatransfer.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_datatransfer.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.datatransfer module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.datatransfer
--- a/test/hotspot/jtreg/applications/ctw/modules/java_desktop.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_desktop.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,8 @@
* @summary run CTW for some classes from java.desktop module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.desktop
--- a/test/hotspot/jtreg/applications/ctw/modules/java_desktop_2.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_desktop_2.java Tue Nov 06 10:01:16 2018 -0800
@@ -26,7 +26,8 @@
* @summary run CTW for some classes from java.desktop module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.desktop
--- a/test/hotspot/jtreg/applications/ctw/modules/java_instrument.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_instrument.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.instrument module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.instrument
--- a/test/hotspot/jtreg/applications/ctw/modules/java_logging.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_logging.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.logging module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.logging
--- a/test/hotspot/jtreg/applications/ctw/modules/java_management.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_management.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.management module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.management
--- a/test/hotspot/jtreg/applications/ctw/modules/java_management_rmi.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_management_rmi.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.management.rmi module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.management.rmi
--- a/test/hotspot/jtreg/applications/ctw/modules/java_naming.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_naming.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.naming module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.naming
--- a/test/hotspot/jtreg/applications/ctw/modules/java_prefs.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_prefs.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.prefs module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.prefs
--- a/test/hotspot/jtreg/applications/ctw/modules/java_rmi.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_rmi.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.rmi module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.rmi
--- a/test/hotspot/jtreg/applications/ctw/modules/java_scripting.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_scripting.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.scripting module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.scripting
--- a/test/hotspot/jtreg/applications/ctw/modules/java_security_jgss.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_security_jgss.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.security.jgss module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.security.jgss
--- a/test/hotspot/jtreg/applications/ctw/modules/java_security_sasl.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_security_sasl.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.security.sasl module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.security.sasl
--- a/test/hotspot/jtreg/applications/ctw/modules/java_smartcardio.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_smartcardio.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.smartcardio module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.smartcardio
--- a/test/hotspot/jtreg/applications/ctw/modules/java_sql.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_sql.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.sql module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.sql
--- a/test/hotspot/jtreg/applications/ctw/modules/java_sql_rowset.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_sql_rowset.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.sql.rowset module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.sql.rowset
--- a/test/hotspot/jtreg/applications/ctw/modules/java_xml.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_xml.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.xml module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.xml
--- a/test/hotspot/jtreg/applications/ctw/modules/java_xml_crypto.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/java_xml_crypto.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from java.xml.crypto module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules java.xml.crypto
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_accessibility.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_accessibility.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.accessibility module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.accessibility
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_aot.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_aot.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.aot module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.aot
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_attach.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_attach.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.attach module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.attach
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_charsets.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_charsets.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.charsets module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.charsets
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_compiler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_compiler.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.compiler module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.compiler
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_cryptoki.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_cryptoki.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.crypto.cryptoki module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.crypto.cryptoki
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_ec.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_ec.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.crypto.ec module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.crypto.ec
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_mscapi.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_mscapi.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.crypto.mscapi module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.crypto.mscapi
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_ucrypto.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_crypto_ucrypto.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.crypto.ucrypto module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.crypto.ucrypto
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_dynalink.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_dynalink.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.dynalink module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.dynalink
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_editpad.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_editpad.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.editpad module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.editpad
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_hotspot_agent.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_hotspot_agent.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.hotspot.agent module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.hotspot.agent
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_httpserver.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_httpserver.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.httpserver module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.httpserver
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_incubator_httpclient.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_incubator_httpclient.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.incubator.httpclient module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.incubator.httpclient
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_ed.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_ed.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.ed module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.ed
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_jvmstat.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_jvmstat.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.jvmstat module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.jvmstat
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_le.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_le.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.le module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.le
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_opt.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_opt.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.opt module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.opt
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_ci.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_ci.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.vm.ci module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.vm.ci
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_compiler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_compiler.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.vm.compiler module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.vm.compiler
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_compiler_management.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_internal_vm_compiler_management.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.internal.vm.compiler.management module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.internal.vm.compiler.management
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jartool.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jartool.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jartool module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jartool
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_javadoc.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_javadoc.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.javadoc module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.javadoc
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jcmd.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jcmd.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jcmd module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jcmd
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jconsole.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jconsole.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jconsole module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jconsole
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jdeps.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jdeps.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jdeps module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jdeps
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jdi.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jdi.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jdi module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jdi
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jlink.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jlink.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jlink module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jlink
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jshell.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jshell.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jshell module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jshell
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jsobject.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jsobject.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jsobject module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jsobject
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_jstatd.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_jstatd.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.jstatd module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.jstatd
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_localedata.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_localedata.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.localedata module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.localedata
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_management.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_management.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.management module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.management
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_management_agent.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_management_agent.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.management.agent module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.management.agent
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_naming_dns.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_naming_dns.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.naming.dns module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.naming.dns
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_naming_rmi.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_naming_rmi.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.naming.rmi module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.naming.rmi
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_net.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_net.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.net module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.net
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_packager.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_packager.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.packager module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.packager
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_packager_services.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_packager_services.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.packager.services module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.packager.services
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_rmic.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_rmic.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.rmic module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.rmic
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_scripting_nashorn.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_scripting_nashorn.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.scripting.nashorn module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.scripting.nashorn
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_scripting_nashorn_shell.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_scripting_nashorn_shell.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.scripting.nashorn.shell module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.scripting.nashorn.shell
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_sctp.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_sctp.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.sctp module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.sctp
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_security_auth.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_security_auth.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.security.auth module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.security.auth
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_security_jgss.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_security_jgss.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.security.jgss module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.security.jgss
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_unsupported.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_unsupported.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.unsupported module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.unsupported
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_xml_dom.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_xml_dom.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.xml.dom module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.xml.dom
--- a/test/hotspot/jtreg/applications/ctw/modules/jdk_zipfs.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/applications/ctw/modules/jdk_zipfs.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,8 @@
* @summary run CTW for all classes from jdk.zipfs module
*
* @library /test/lib / /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* @modules jdk.zipfs
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,7 +28,7 @@
import compiler.jvmci.common.testcases.MultipleImplementersInterface;
import compiler.jvmci.compilerToVM.ConstantPoolTestCase.ConstantTypes;
import compiler.jvmci.compilerToVM.ConstantPoolTestCase.TestedCPEntry;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.org.objectweb.asm.Opcodes;
import jdk.internal.reflect.ConstantPool;
import jdk.internal.reflect.ConstantPool.Tag;
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,7 +28,7 @@
* @summary Testing compiler.jvmci.CompilerToVM.lookupKlassInPool method
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupTypeTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/LookupTypeTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library / /test/lib
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot
* @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper
* @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* jdk.internal.vm.ci/jdk.vm.ci.hotspot
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,8 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@
* @requires vm.jvmci
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* java.base/jdk.internal.org.objectweb.asm.tree
--- a/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,7 +28,7 @@
* @summary Testing compiler.jvmci.CompilerToVM.resolveTypeInPool method
* @library /test/lib /
* @library ../common/patches
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* java.base/jdk.internal.org.objectweb.asm
* jdk.internal.vm.ci/jdk.vm.ci.hotspot
--- a/test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/EmptyClassInBootClassPath.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/EmptyClassInBootClassPath.java Tue Nov 06 10:01:16 2018 -0800
@@ -31,7 +31,7 @@
* "--limit-modules java.base" option is specified
* @requires vm.cds & !vm.graal.enabled
* @library /test/lib /test/hotspot/jtreg/runtime/appcds
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.management
* jdk.jartool/sun.tools.jar
* jdk.internal.jvmstat/sun.jvmstat.monitor
@@ -66,7 +66,7 @@
List<String> argsList = new ArrayList<String>();
argsList.add(classPath);
argsList.add(bootclasspath);
- argsList.add("--add-exports=java.base/jdk.internal.misc=ALL-UNNAMED");
+ argsList.add("--add-exports=java.base/jdk.internal.access=ALL-UNNAMED");
argsList.add("EmptyClassHelper");
// case 1: load class in bootclasspath using app loader
--- a/test/hotspot/jtreg/runtime/appcds/test-classes/EmptyClassHelper.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/runtime/appcds/test-classes/EmptyClassHelper.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,9 +23,10 @@
*/
import java.lang.*;
-import java.lang.reflect.*;
-import jdk.internal.misc.JavaLangAccess;
-import jdk.internal.misc.SharedSecrets;
+
+import java.lang.reflect.Method;
+import jdk.internal.access.JavaLangAccess;
+import jdk.internal.access.SharedSecrets;
class EmptyClassHelper {
static final JavaLangAccess jla = SharedSecrets.getJavaLangAccess();
--- a/test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/Compiler.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/Compiler.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,7 @@
package sun.hotspot.tools.ctw;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.misc.Unsafe;
import jdk.internal.reflect.ConstantPool;
import sun.hotspot.WhiteBox;
--- a/test/hotspot/jtreg/testlibrary_tests/ctw/ClassesDirTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary_tests/ctw/ClassesDirTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,8 @@
* @test
* @bug 8012447
* @library /test/lib /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* java.management
--- a/test/hotspot/jtreg/testlibrary_tests/ctw/ClassesListTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary_tests/ctw/ClassesListTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,8 @@
* @test
* @bug 8012447
* @library /test/lib /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* java.management
--- a/test/hotspot/jtreg/testlibrary_tests/ctw/CtwTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary_tests/ctw/CtwTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -49,6 +49,7 @@
"-XX:+UnlockDiagnosticVMOptions",
"-XX:+WhiteBoxAPI",
"-Dsun.hotspot.tools.ctw.logfile=" + LOG_FILE,
+ "--add-exports", "java.base/jdk.internal.access=ALL-UNNAMED",
"--add-exports", "java.base/jdk.internal.jimage=ALL-UNNAMED",
"--add-exports", "java.base/jdk.internal.misc=ALL-UNNAMED",
"--add-exports", "java.base/jdk.internal.reflect=ALL-UNNAMED",
--- a/test/hotspot/jtreg/testlibrary_tests/ctw/JarDirTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary_tests/ctw/JarDirTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,8 @@
* @test
* @bug 8012447
* @library /test/lib /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* java.compiler
--- a/test/hotspot/jtreg/testlibrary_tests/ctw/JarsTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/hotspot/jtreg/testlibrary_tests/ctw/JarsTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,8 @@
* @test
* @bug 8012447
* @library /test/lib /testlibrary/ctw/src
- * @modules java.base/jdk.internal.jimage
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.jimage
* java.base/jdk.internal.misc
* java.base/jdk.internal.reflect
* java.compiler
--- a/test/jdk/java/io/Serializable/serialFilter/CheckArrayTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/io/Serializable/serialFilter/CheckArrayTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -28,11 +28,8 @@
import java.io.ObjectInputStream;
import java.io.InvalidClassException;
-import java.util.Hashtable;
+import jdk.internal.access.SharedSecrets;
-import jdk.internal.misc.SharedSecrets;
-
-import org.testng.annotations.BeforeClass;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
import org.testng.Assert;
@@ -40,7 +37,7 @@
/* @test
* @build CheckArrayTest SerialFilterTest
* @bug 8203368
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* @run testng CheckArrayTest
*
* @summary Test the SharedSecret access to ObjectInputStream.checkArray works
--- a/test/jdk/java/lang/ModuleLayer/BasicLayerTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/lang/ModuleLayer/BasicLayerTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -24,7 +24,7 @@
/**
* @test
* @library /test/lib
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* @build BasicLayerTest
* jdk.test.lib.util.ModuleUtils
* @compile layertest/Test.java
@@ -38,13 +38,12 @@
import java.lang.module.ModuleFinder;
import java.util.HashMap;
import java.util.Map;
-import java.util.Optional;
import java.util.Set;
import java.util.stream.Collectors;
import jdk.test.lib.util.ModuleUtils;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
--- a/test/jdk/java/lang/module/ConfigurationTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/lang/module/ConfigurationTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -24,7 +24,7 @@
/**
* @test
* @library /test/lib
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.module
* @build ConfigurationTest
* jdk.test.lib.util.ModuleUtils
@@ -45,12 +45,11 @@
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.List;
-import java.util.Optional;
import java.util.Set;
import jdk.test.lib.util.ModuleUtils;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.ModuleInfoWriter;
import jdk.internal.module.ModuleTarget;
import org.testng.annotations.DataProvider;
--- a/test/jdk/java/lang/module/ModuleDescriptorTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/lang/module/ModuleDescriptorTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,8 +23,8 @@
/**
* @test
- * @modules java.base/jdk.internal.module
- * java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
+ * java.base/jdk.internal.module
* @run testng ModuleDescriptorTest
* @summary Basic test for java.lang.module.ModuleDescriptor and its builder
*/
@@ -49,14 +49,13 @@
import java.util.Iterator;
import java.util.List;
import java.util.Objects;
-import java.util.Optional;
import java.util.Set;
import java.util.stream.Collectors;
import static java.lang.module.ModuleDescriptor.Requires.Modifier.*;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.ModuleInfoWriter;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
--- a/test/jdk/java/lang/module/ModuleNamesTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/lang/module/ModuleNamesTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,7 @@
/**
* @test
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.module
* @run testng ModuleNamesTest
* @summary Basic test of reading a module-info.class with module names that
@@ -41,7 +41,7 @@
import java.util.Optional;
import java.util.Set;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
import jdk.internal.module.ModuleInfoWriter;
import org.testng.annotations.DataProvider;
--- a/test/jdk/java/net/InetAddress/getOriginalHostName.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/net/InetAddress/getOriginalHostName.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,14 +25,13 @@
* @test
* @bug 8133196
* @summary test functionality of getOriginalHostName(InetAddress)
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
*/
-import java.io.*;
import java.net.InetAddress;
-import jdk.internal.misc.JavaNetInetAddressAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaNetInetAddressAccess;
+import jdk.internal.access.SharedSecrets;
public class getOriginalHostName {
--- a/test/jdk/java/security/ProtectionDomain/PreserveCombinerTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/security/ProtectionDomain/PreserveCombinerTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@
import java.security.DomainCombiner;
import java.security.PrivilegedAction;
import java.security.ProtectionDomain;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
/*
* @test
@@ -34,7 +34,7 @@
* @summary Make sure that JavaSecurityAccess.doIntersectionPrivilege()
* is not dropping the information about the domain combiner of
* the stack ACC
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
*/
public class PreserveCombinerTest {
--- a/test/jdk/java/util/logging/LogManagerAppContextDeadlock.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/util/logging/LogManagerAppContextDeadlock.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -35,15 +35,15 @@
import java.util.concurrent.atomic.AtomicInteger;
import java.util.logging.LogManager;
import java.util.logging.Logger;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
/**
* @test
* @bug 8065991
* @summary check that when LogManager is initialized, a deadlock similar
* to that described in 8065709 will not occur.
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.logging
* java.management
* @run main/othervm LogManagerAppContextDeadlock UNSECURE
@@ -349,7 +349,7 @@
// FileHandlers because we're passing invalid parameters
// which will make the creation fail...
permissions = new Permissions();
- permissions.add(new RuntimePermission("accessClassInPackage.jdk.internal.misc"));
+ permissions.add(new RuntimePermission("accessClassInPackage.jdk.internal.access"));
// these are used for configuring the test itself...
allPermissions = new Permissions();
--- a/test/jdk/java/util/logging/RootLogger/RootLevelInConfigFile.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/util/logging/RootLogger/RootLevelInConfigFile.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,15 +34,15 @@
import java.util.logging.LogManager;
import java.util.logging.Logger;
import java.util.logging.LoggingPermission;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
/**
* @test
* @bug 8030850
* @summary Tests that setting .level=FINEST for the root logger in logging
* configuration file does work.
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.logging
* @run main/othervm RootLevelInConfigFile
*
@@ -182,7 +182,7 @@
perms.add(new PropertyPermission("java.util.logging.config.class","read"));
perms.add(new PropertyPermission("java.util.logging.config.file","read"));
perms.add(new FilePermission(configFile, "read"));
- perms.add(new RuntimePermission("accessClassInPackage.jdk.internal.misc"));
+ perms.add(new RuntimePermission("accessClassInPackage.jdk.internal.access"));
}
@Override
--- a/test/jdk/java/util/logging/TestAppletLoggerContext.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/util/logging/TestAppletLoggerContext.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -33,8 +33,8 @@
import java.util.logging.LogManager;
import java.util.logging.Logger;
import java.util.logging.LoggingPermission;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
/*
* @test
@@ -42,7 +42,7 @@
* @summary NPE when using Logger.getAnonymousLogger or
* LogManager.getLogManager().getLogger
*
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.logging
* @run main/othervm -Dtest.security=off TestAppletLoggerContext LoadingApplet
* @run main/othervm -Dtest.security=on TestAppletLoggerContext LoadingApplet
--- a/test/jdk/java/util/logging/TestGetLoggerNPE.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/java/util/logging/TestGetLoggerNPE.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,8 @@
import java.security.ProtectionDomain;
import java.util.logging.LogManager;
import java.util.logging.Logger;
-import jdk.internal.misc.JavaAWTAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaAWTAccess;
+import jdk.internal.access.SharedSecrets;
/*
* @test
@@ -35,7 +35,7 @@
*
* @summary NPE with logging while launching webstart
*
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.logging
* @build TestGetLoggerNPE
* @run main/othervm TestGetLoggerNPE getLogger
--- a/test/jdk/jdk/internal/reflect/constantPool/ConstantPoolTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/jdk/internal/reflect/constantPool/ConstantPoolTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -25,7 +25,7 @@
* @test
* @bug 8141615
* @summary Tests new public methods at ConstantPool
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* java.base/jdk.internal.reflect
* @library /test/lib
* @compile ConstantPoolTestDummy.jasm
@@ -36,9 +36,9 @@
import java.util.HashMap;
import java.util.Map;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.SharedSecrets;
+import jdk.internal.reflect.ConstantPool;
import jdk.test.lib.Asserts;
-import jdk.internal.reflect.ConstantPool;
public class ConstantPoolTest {
--- a/test/jdk/tools/jar/modularJar/src/bar/jdk/test/bar/Bar.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/tools/jar/modularJar/src/bar/jdk/test/bar/Bar.java Tue Nov 06 10:01:16 2018 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -32,8 +32,7 @@
import java.util.StringJoiner;
import java.util.HashSet;
import java.util.Set;
-import jdk.internal.misc.SharedSecrets;
-import jdk.internal.misc.JavaLangModuleAccess;
+
import jdk.internal.module.ModuleHashes;
import jdk.internal.module.ModuleReferenceImpl;
import jdk.test.bar.internal.Message;
--- a/test/jdk/tools/jlink/plugins/SystemModuleDescriptors/SystemModulesTest.java Tue Nov 06 17:28:14 2018 +0100
+++ b/test/jdk/tools/jlink/plugins/SystemModuleDescriptors/SystemModulesTest.java Tue Nov 06 10:01:16 2018 -0800
@@ -34,15 +34,15 @@
import java.util.Map;
import java.util.Set;
-import jdk.internal.misc.JavaLangModuleAccess;
-import jdk.internal.misc.SharedSecrets;
+import jdk.internal.access.JavaLangModuleAccess;
+import jdk.internal.access.SharedSecrets;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
/**
* @test
* @bug 8142968 8173381
- * @modules java.base/jdk.internal.misc
+ * @modules java.base/jdk.internal.access
* @modules java.base/jdk.internal.module
* @modules java.base/jdk.internal.org.objectweb.asm
* @build ModuleTargetHelper