--- old/src/java.base/share/classes/java/lang/Class.java 2017-01-09 17:40:45.205655566 -0800 +++ new/src/java.base/share/classes/java/lang/Class.java 2017-01-09 17:40:45.033655569 -0800 @@ -2477,7 +2477,7 @@ * * @@ -2570,7 +2570,7 @@ * * --- old/src/java.base/share/classes/java/lang/ClassLoader.java 2017-01-09 17:40:45.765655555 -0800 +++ new/src/java.base/share/classes/java/lang/ClassLoader.java 2017-01-09 17:40:45.597655558 -0800 @@ -70,34 +70,34 @@ /** * A class loader is an object that is responsible for loading classes. The - * class ClassLoader is an abstract class. Given the binary name of a class, a class loader should attempt to * locate or generate data that constitutes a definition for the class. A * typical strategy is to transform the name into a file name and then read a * "class file" of that name from a file system. * - *

Every {@link Class Class} object contains a {@link - * Class#getClassLoader() reference} to the ClassLoader that defined + *

Every {@link java.lang.Class Class} object contains a {@link + * Class#getClassLoader() reference} to the {@code ClassLoader} that defined * it. * - *

Class objects for array classes are not created by class + *

{@code Class} objects for array classes are not created by class * loaders, but are created automatically as required by the Java runtime. * The class loader for an array class, as returned by {@link * Class#getClassLoader()} is the same as the class loader for its element * type; if the element type is a primitive type, then the array class has no * class loader. * - *

Applications implement subclasses of ClassLoader in order to + *

Applications implement subclasses of {@code ClassLoader} in order to * extend the manner in which the Java virtual machine dynamically loads * classes. * *

Class loaders may typically be used by security managers to indicate * security domains. * - *

The ClassLoader class uses a delegation model to search for - * classes and resources. Each instance of ClassLoader has an + *

The {@code ClassLoader} class uses a delegation model to search for + * classes and resources. Each instance of {@code ClassLoader} has an * associated parent class loader. When requested to find a class or - * resource, a ClassLoader instance will delegate the search for the + * resource, a {@code ClassLoader} instance will delegate the search for the * class or resource to its parent class loader before attempting to find the * class or resource itself. * @@ -105,15 +105,15 @@ * {@linkplain #isRegisteredAsParallelCapable() parallel capable} class * loaders and are required to register themselves at their class initialization * time by invoking the {@link - * #registerAsParallelCapable ClassLoader.registerAsParallelCapable} - * method. Note that the ClassLoader class is registered as parallel + * #registerAsParallelCapable ClassLoader.registerAsParallelCapable} + * method. Note that the {@code ClassLoader} class is registered as parallel * capable by default. However, its subclasses still need to register themselves * if they are parallel capable. * In environments in which the delegation model is not strictly * hierarchical, class loaders need to be parallel capable, otherwise class * loading can lead to deadlocks because the loader lock is held for the * duration of the class loading process (see {@link #loadClass - * loadClass} methods). + * loadClass} methods). * *

Run-time Built-in Class Loaders

* @@ -143,13 +143,13 @@ * However, some classes may not originate from a file; they may originate * from other sources, such as the network, or they could be constructed by an * application. The method {@link #defineClass(String, byte[], int, int) - * defineClass} converts an array of bytes into an instance of class - * Class. Instances of this newly defined class can be created using - * {@link Class#newInstance Class.newInstance}. + * defineClass} converts an array of bytes into an instance of class + * {@code Class}. Instances of this newly defined class can be created using + * {@link Class#newInstance Class.newInstance}. * *

The methods and constructors of objects created by a class loader may * reference other classes. To determine the class(es) referred to, the Java - * virtual machine invokes the {@link #loadClass loadClass} method of + * virtual machine invokes the {@link #loadClass loadClass} method of * the class loader that originally created the class. * *

For example, an application could create a network class loader to @@ -162,9 +162,9 @@ * * *

The network class loader subclass must define the methods {@link - * #findClass findClass} and loadClassData to load a class + * #findClass findClass} and {@code loadClassData} to load a class * from the network. Once it has downloaded the bytes that make up the class, - * it should use the method {@link #defineClass defineClass} to + * it should use the method {@link #defineClass defineClass} to * create a class instance. A sample implementation is: * *

@@ -392,7 +392,7 @@
      *
      * 

If there is a security manager, its {@link * SecurityManager#checkCreateClassLoader() - * checkCreateClassLoader} method is invoked. This may result in + * checkCreateClassLoader} method is invoked. This may result in * a security exception.

* * @param parent @@ -400,7 +400,7 @@ * * @throws SecurityException * If a security manager exists and its - * checkCreateClassLoader method doesn't allow creation + * {@code checkCreateClassLoader} method doesn't allow creation * of a new class loader. * * @since 1.2 @@ -410,18 +410,18 @@ } /** - * Creates a new class loader using the ClassLoader returned by + * Creates a new class loader using the {@code ClassLoader} returned by * the method {@link #getSystemClassLoader() - * getSystemClassLoader()} as the parent class loader. + * getSystemClassLoader()} as the parent class loader. * *

If there is a security manager, its {@link * SecurityManager#checkCreateClassLoader() - * checkCreateClassLoader} method is invoked. This may result in + * checkCreateClassLoader} method is invoked. This may result in * a security exception.

* * @throws SecurityException * If a security manager exists and its - * checkCreateClassLoader method doesn't allow creation + * {@code checkCreateClassLoader} method doesn't allow creation * of a new class loader. */ protected ClassLoader() { @@ -458,13 +458,13 @@ * This method searches for classes in the same manner as the {@link * #loadClass(String, boolean)} method. It is invoked by the Java virtual * machine to resolve class references. Invoking this method is equivalent - * to invoking {@link #loadClass(String, boolean) loadClass(name, - * false)}. + * to invoking {@link #loadClass(String, boolean) loadClass(name, + * false)}. * * @param name * The binary name of the class * - * @return The resulting Class object + * @return The resulting {@code Class} object * * @throws ClassNotFoundException * If the class was not found @@ -483,8 +483,8 @@ *
  • Invoke {@link #findLoadedClass(String)} to check if the class * has already been loaded.

  • * - *
  • Invoke the {@link #loadClass(String) loadClass} method - * on the parent class loader. If the parent is null the class + *

  • Invoke the {@link #loadClass(String) loadClass} method + * on the parent class loader. If the parent is {@code null} the class * loader built-in to the virtual machine is used, instead.

  • * *
  • Invoke the {@link #findClass(String)} method to find the @@ -493,23 +493,23 @@ * * *

    If the class was found using the above steps, and the - * resolve flag is true, this method will then invoke the {@link - * #resolveClass(Class)} method on the resulting Class object. + * {@code resolve} flag is true, this method will then invoke the {@link + * #resolveClass(Class)} method on the resulting {@code Class} object. * - *

    Subclasses of ClassLoader are encouraged to override {@link + *

    Subclasses of {@code ClassLoader} are encouraged to override {@link * #findClass(String)}, rather than this method.

    * *

    Unless overridden, this method synchronizes on the result of - * {@link #getClassLoadingLock getClassLoadingLock} method + * {@link #getClassLoadingLock getClassLoadingLock} method * during the entire class loading process. * * @param name * The binary name of the class * * @param resolve - * If true then resolve the class + * If {@code true} then resolve the class * - * @return The resulting Class object + * @return The resulting {@code Class} object * * @throws ClassNotFoundException * If the class could not be found @@ -606,7 +606,7 @@ * @return the lock for class loading operations * * @throws NullPointerException - * If registered as parallel capable and className is null + * If registered as parallel capable and {@code className} is null * * @see #loadClass(String, boolean) * @@ -667,14 +667,14 @@ * Finds the class with the specified binary name. * This method should be overridden by class loader implementations that * follow the delegation model for loading classes, and will be invoked by - * the {@link #loadClass loadClass} method after checking the + * the {@link #loadClass loadClass} method after checking the * parent class loader for the requested class. The default implementation - * throws a ClassNotFoundException. + * throws a {@code ClassNotFoundException}. * * @param name * The binary name of the class * - * @return The resulting Class object + * @return The resulting {@code Class} object * * @throws ClassNotFoundException * If the class could not be found @@ -722,32 +722,32 @@ /** - * Converts an array of bytes into an instance of class Class. - * Before the Class can be used it must be resolved. This method + * Converts an array of bytes into an instance of class {@code Class}. + * Before the {@code Class} can be used it must be resolved. This method * is deprecated in favor of the version that takes a binary name as its first argument, and is more secure. * * @param b * The bytes that make up the class data. The bytes in positions - * off through off+len-1 should have the format + * {@code off} through {@code off+len-1} should have the format * of a valid class file as defined by * The Java™ Virtual Machine Specification. * * @param off - * The start offset in b of the class data + * The start offset in {@code b} of the class data * * @param len * The length of the class data * - * @return The Class object that was created from the specified + * @return The {@code Class} object that was created from the specified * class data * * @throws ClassFormatError * If the data did not contain a valid class * * @throws IndexOutOfBoundsException - * If either off or len is negative, or if - * off+len is greater than b.length. + * If either {@code off} or {@code len} is negative, or if + * {@code off+len} is greater than {@code b.length}. * * @throws SecurityException * If an attempt is made to add this class to a package that @@ -994,11 +994,11 @@ * #defineClass(String, byte[], int, int, ProtectionDomain)}. * *

    An invocation of this method of the form - * cl.defineClass(name, - * bBuffer, pd) yields exactly the same + * cl{@code .defineClass(}name{@code ,} + * bBuffer{@code ,} pd{@code )} yields exactly the same * result as the statements * - *

    + *

    * ...
    * byte[] temp = new byte[bBuffer.{@link * java.nio.ByteBuffer#remaining remaining}()];
    @@ -1007,16 +1007,16 @@ * return {@link #defineClass(String, byte[], int, int, ProtectionDomain) * cl.defineClass}(name, temp, 0, * temp.length, pd);
    - *

    + *

    * * @param name * The expected binary name. of the class, or - * null if not known + * {@code null} if not known * * @param b * The bytes that make up the class data. The bytes from positions - * b.position() through b.position() + b.limit() -1 - * should have the format of a valid class file as defined by + * {@code b.position()} through {@code b.position() + b.limit() -1 + * } should have the format of a valid class file as defined by * The Java™ Virtual Machine Specification. * * @param protectionDomain @@ -1158,7 +1158,7 @@ /** * Links the specified class. This (misleadingly named) method may be - * used by a class loader to link a class. If the class c has + * used by a class loader to link a class. If the class {@code c} has * already been linked, then this method simply returns. Otherwise, the * class is linked as described in the "Execution" chapter of * The Java™ Language Specification. @@ -1167,7 +1167,7 @@ * The class to link * * @throws NullPointerException - * If c is null. + * If {@code c} is {@code null}. * * @see #defineClass(String, byte[], int, int) */ @@ -1182,16 +1182,16 @@ * loading it if necessary. * *

    This method loads the class through the system class loader (see - * {@link #getSystemClassLoader()}). The Class object returned - * might have more than one ClassLoader associated with it. - * Subclasses of ClassLoader need not usually invoke this method, + * {@link #getSystemClassLoader()}). The {@code Class} object returned + * might have more than one {@code ClassLoader} associated with it. + * Subclasses of {@code ClassLoader} need not usually invoke this method, * because most class loaders need to override just {@link * #findClass(String)}.

    * * @param name * The binary name of the class * - * @return The Class object for the specified name + * @return The {@code Class} object for the specified {@code name} * * @throws ClassNotFoundException * If the class could not be found @@ -1222,12 +1222,12 @@ * Returns the class with the given binary name if this * loader has been recorded by the Java virtual machine as an initiating * loader of a class with that binary name. Otherwise - * null is returned. + * {@code null} is returned. * * @param name * The binary name of the class * - * @return The Class object, or null if the class has + * @return The {@code Class} object, or {@code null} if the class has * not been loaded * * @since 1.1 @@ -1245,7 +1245,7 @@ * class. * * @param c - * The Class object + * The {@code Class} object * * @param signers * The signers for the class @@ -1306,11 +1306,11 @@ * (images, audio, text, etc) that can be accessed by class code in a way * that is independent of the location of the code. * - *

    The name of a resource is a '/'-separated path name that + *

    The name of a resource is a '{@code /}'-separated path name that * identifies the resource. * *

    This method will first search the parent class loader for the - * resource; if the parent is null the path of the class loader + * resource; if the parent is {@code null} the path of the class loader * built-in to the virtual machine is searched. That failing, this method * will invoke {@link #findResource(String)} to find the resource.

    * @@ -1362,7 +1362,7 @@ * (images, audio, text, etc) that can be accessed by class code in a way * that is independent of the location of the code. * - *

    The name of a resource is a /-separated path name that + *

    The name of a resource is a {@code /}-separated path name that * identifies the resource. * *

    The delegation order for searching is described in the documentation @@ -1389,7 +1389,7 @@ * @param name * The resource name * - * @return An enumeration of {@link java.net.URL URL} objects for + * @return An enumeration of {@link java.net.URL URL} objects for * the resource. If no resources could be found, the enumeration * will be empty. Resources for which a {@code URL} cannot be * constructed, are in package that is not opened unconditionally, @@ -1505,7 +1505,7 @@ } /** - * Returns an enumeration of {@link java.net.URL URL} objects + * Returns an enumeration of {@link java.net.URL URL} objects * representing all the resources with the given name. Class loader * implementations should override this method to specify where to load * resources from. @@ -1520,7 +1520,7 @@ * @param name * The resource name * - * @return An enumeration of {@link java.net.URL URL} objects for + * @return An enumeration of {@link java.net.URL URL} objects for * the resource. If no resources could be found, the enumeration * will be empty. Resources for which a {@code URL} cannot be * constructed, are in a package that is not opened unconditionally, @@ -1594,7 +1594,7 @@ * @param name * The resource name * - * @return A {@link java.net.URL URL} to the resource; {@code + * @return A {@link java.net.URL URL} to the resource; {@code * null} if the resource could not be found, a URL could not be * constructed to locate the resource, the resource is in a package * that is not opened unconditionally or access to the resource is @@ -1609,8 +1609,8 @@ /** * Finds all resources of the specified name from the search path used to * load classes. The resources thus found are returned as an - * {@link java.util.Enumeration Enumeration} of {@link - * java.net.URL URL} objects. + * {@link java.util.Enumeration Enumeration} of {@link + * java.net.URL URL} objects. * *

    The search order is described in the documentation for {@link * #getSystemResource(String)}.

    @@ -1625,7 +1625,7 @@ * @param name * The resource name * - * @return An enumeration of {@link java.net.URL URL} objects for + * @return An enumeration of {@link java.net.URL URL} objects for * the resource. If no resources could be found, the enumeration * will be empty. Resources for which a {@code URL} cannot be * constructed, are in a package that is not opened unconditionally, @@ -1714,11 +1714,11 @@ /** * Returns the parent class loader for delegation. Some implementations may - * use null to represent the bootstrap class loader. This method - * will return null in such implementations if this class loader's + * use {@code null} to represent the bootstrap class loader. This method + * will return {@code null} in such implementations if this class loader's * parent is the bootstrap class loader. * - * @return The parent ClassLoader + * @return The parent {@code ClassLoader} * * @throws SecurityException * If a security manager is present, and the caller's class loader @@ -1785,7 +1785,7 @@ /** * Returns the system class loader for delegation. This is the default - * delegation parent for new ClassLoader instances, and is + * delegation parent for new {@code ClassLoader} instances, and is * typically the class loader used to start the application. * *

    This method is first invoked early in the runtime's startup @@ -1797,12 +1797,12 @@ *

    The default system class loader is an implementation-dependent * instance of this class. * - *

    If the system property "java.system.class.loader" is defined + *

    If the system property "{@code java.system.class.loader}" is defined * when this method is first invoked then the value of that property is * taken to be the name of a class that will be returned as the system * class loader. The class is loaded using the default system class loader * and must define a public constructor that takes a single parameter of - * type ClassLoader which is used as the delegation parent. An + * type {@code ClassLoader} which is used as the delegation parent. An * instance is then created using this constructor with the default system * class loader as the parameter. The resulting class loader is defined * to be the system class loader. During construction, the class loader @@ -1825,7 +1825,7 @@ * the application module path then the class path defaults to * the current working directory. * - * @return The system ClassLoader for delegation + * @return The system {@code ClassLoader} for delegation * * @throws SecurityException * If a security manager is present, and the caller's class loader @@ -1835,11 +1835,11 @@ * * @throws IllegalStateException * If invoked recursively during the construction of the class - * loader specified by the "java.system.class.loader" + * loader specified by the "{@code java.system.class.loader}" * property. * * @throws Error - * If the system property "java.system.class.loader" + * If the system property "{@code java.system.class.loader}" * is defined but the named class could not be loaded, the * provider class does not define the required constructor, or an * exception is thrown by that constructor when it is invoked. The @@ -2249,9 +2249,9 @@ /** * Returns the absolute path name of a native library. The VM invokes this * method to locate the native libraries that belong to classes loaded with - * this class loader. If this method returns null, the VM + * this class loader. If this method returns {@code null}, the VM * searches the library along the path specified as the - * "java.library.path" property. + * "{@code java.library.path}" property. * * @param libname * The library name @@ -2270,12 +2270,12 @@ /** * The inner class NativeLibrary denotes a loaded native library instance. * Every classloader contains a vector of loaded native libraries in the - * private field nativeLibraries. The native libraries loaded - * into the system are entered into the systemNativeLibraries + * private field {@code nativeLibraries}. The native libraries loaded + * into the system are entered into the {@code systemNativeLibraries} * vector. * *

    Every native library requires a particular version of JNI. This is - * denoted by the private jniVersion field. This field is set by + * denoted by the private {@code jniVersion} field. This field is set by * the VM when it loads the library, and used by the VM to pass the correct * version of JNI to the native methods.

    * @@ -2592,8 +2592,8 @@ * #setClassAssertionStatus(String, boolean)}. * * @param enabled - * true if classes loaded by this class loader will - * henceforth have assertions enabled by default, false + * {@code true} if classes loaded by this class loader will + * henceforth have assertions enabled by default, {@code false} * if they will have assertions disabled by default. * * @since 1.4 @@ -2614,16 +2614,16 @@ * any of its "subpackages". * *

    A subpackage of a package named p is any package whose name begins - * with "p.". For example, javax.swing.text is a - * subpackage of javax.swing, and both java.util and - * java.lang.reflect are subpackages of java. + * with "{@code p.}". For example, {@code javax.swing.text} is a + * subpackage of {@code javax.swing}, and both {@code java.util} and + * {@code java.lang.reflect} are subpackages of {@code java}. * *

    In the event that multiple package defaults apply to a given class, * the package default pertaining to the most specific package takes - * precedence over the others. For example, if javax.lang and - * javax.lang.reflect both have package defaults associated with + * precedence over the others. For example, if {@code javax.lang} and + * {@code javax.lang.reflect} both have package defaults associated with * them, the latter package default applies to classes in - * javax.lang.reflect. + * {@code javax.lang.reflect}. * *

    Package defaults take precedence over the class loader's default * assertion status, and may be overridden on a per-class basis by invoking @@ -2631,15 +2631,15 @@ * * @param packageName * The name of the package whose package default assertion status - * is to be set. A null value indicates the unnamed + * is to be set. A {@code null} value indicates the unnamed * package that is "current" * (see section 7.4.2 of * The Java™ Language Specification.) * * @param enabled - * true if classes loaded by this classloader and + * {@code true} if classes loaded by this classloader and * belonging to the named package or any of its subpackages will - * have assertions enabled by default, false if they will + * have assertions enabled by default, {@code false} if they will * have assertions disabled by default. * * @since 1.4 @@ -2670,8 +2670,8 @@ * assertion status is to be set. * * @param enabled - * true if the named class is to have assertions - * enabled when (and if) it is initialized, false if the + * {@code true} if the named class is to have assertions + * enabled when (and if) it is initialized, {@code false} if the * class is to have assertions disabled. * * @since 1.4 @@ -2687,7 +2687,7 @@ /** * Sets the default assertion status for this class loader to - * false and discards any package defaults or class assertion + * {@code false} and discards any package defaults or class assertion * status settings associated with the class loader. This method is * provided so that class loaders can be made to ignore any command line or * persistent assertion status settings and "start with a clean slate."