From f0cd136c7451522e69be2ba06759cdfb73a28155 Mon Sep 17 00:00:00 2001 From: Roger Riggs Date: Mon, 12 Mar 2018 10:04:12 -0400 Subject: 8199420: Update javadoc tags in java.lang.System and related Reviewed-by: lancea, bpb --- src/java.base/share/classes/java/lang/System.java | 404 +++++++++++----------- 1 file changed, 196 insertions(+), 208 deletions(-) (limited to 'src/java.base/share/classes/java/lang/System.java') diff --git a/src/java.base/share/classes/java/lang/System.java b/src/java.base/share/classes/java/lang/System.java index 885381eaa80..d4cd69b1e1f 100644 --- a/src/java.base/share/classes/java/lang/System.java +++ b/src/java.base/share/classes/java/lang/System.java @@ -74,20 +74,19 @@ import sun.nio.ch.Interruptible; import sun.security.util.SecurityConstants; /** - * The System class contains several useful class fields + * The {@code System} class contains several useful class fields * and methods. It cannot be instantiated. * - *

Among the facilities provided by the System class + * Among the facilities provided by the {@code System} class * are standard input, standard output, and error output streams; * access to externally defined properties and environment * variables; a means of loading files and libraries; and a utility * method for quickly copying a portion of an array. * - * @author unascribed * @since 1.0 */ public final class System { - /* register the natives via the static initializer. + /* Register the natives via the static initializer. * * VM will invoke the initializeSystemClass method to complete * the initialization for this class separated from clinit. @@ -123,7 +122,7 @@ public final class System { * System.out.println(data) * *

- * See the println methods in class PrintStream. + * See the {@code println} methods in class {@code PrintStream}. * * @see java.io.PrintStream#println() * @see java.io.PrintStream#println(boolean) @@ -147,7 +146,7 @@ public final class System { * convention, this output stream is used to display error messages * or other information that should come to the immediate attention * of a user even if the principal output stream, the value of the - * variable out, has been redirected to a file or other + * variable {@code out}, has been redirected to a file or other * destination that is typically not continuously monitored. */ public static final PrintStream err = null; @@ -159,15 +158,15 @@ public final class System { /** * Reassigns the "standard" input stream. * - *

First, if there is a security manager, its checkPermission - * method is called with a RuntimePermission("setIO") permission + * First, if there is a security manager, its {@code checkPermission} + * method is called with a {@code RuntimePermission("setIO")} permission * to see if it's ok to reassign the "standard" input stream. * * @param in the new standard input stream. * * @throws SecurityException * if a security manager exists and its - * checkPermission method doesn't allow + * {@code checkPermission} method doesn't allow * reassigning of the standard input stream. * * @see SecurityManager#checkPermission @@ -183,15 +182,15 @@ public final class System { /** * Reassigns the "standard" output stream. * - *

First, if there is a security manager, its checkPermission - * method is called with a RuntimePermission("setIO") permission + * First, if there is a security manager, its {@code checkPermission} + * method is called with a {@code RuntimePermission("setIO")} permission * to see if it's ok to reassign the "standard" output stream. * * @param out the new standard output stream * * @throws SecurityException * if a security manager exists and its - * checkPermission method doesn't allow + * {@code checkPermission} method doesn't allow * reassigning of the standard output stream. * * @see SecurityManager#checkPermission @@ -207,15 +206,15 @@ public final class System { /** * Reassigns the "standard" error output stream. * - *

First, if there is a security manager, its checkPermission - * method is called with a RuntimePermission("setIO") permission + * First, if there is a security manager, its {@code checkPermission} + * method is called with a {@code RuntimePermission("setIO")} permission * to see if it's ok to reassign the "standard" error output stream. * * @param err the new standard error output stream. * * @throws SecurityException * if a security manager exists and its - * checkPermission method doesn't allow + * {@code checkPermission} method doesn't allow * reassigning of the standard error output stream. * * @see SecurityManager#checkPermission @@ -253,10 +252,10 @@ public final class System { * Returns the channel inherited from the entity that created this * Java virtual machine. * - *

This method returns the channel obtained by invoking the + * This method returns the channel obtained by invoking the * {@link java.nio.channels.spi.SelectorProvider#inheritedChannel * inheritedChannel} method of the system-wide default - * {@link java.nio.channels.spi.SelectorProvider} object.

+ * {@link java.nio.channels.spi.SelectorProvider} object. * *

In addition to the network-oriented channels described in * {@link java.nio.channels.spi.SelectorProvider#inheritedChannel @@ -292,21 +291,21 @@ public final class System { /** * Sets the System security. * - *

If there is a security manager already installed, this method first - * calls the security manager's checkPermission method - * with a RuntimePermission("setSecurityManager") + * If there is a security manager already installed, this method first + * calls the security manager's {@code checkPermission} method + * with a {@code RuntimePermission("setSecurityManager")} * permission to ensure it's ok to replace the existing * security manager. - * This may result in throwing a SecurityException. + * This may result in throwing a {@code SecurityException}. * *

Otherwise, the argument is established as the current - * security manager. If the argument is null and no + * security manager. If the argument is {@code null} and no * security manager has been established, then no action is taken and * the method simply returns. * * @param s the security manager. - * @exception SecurityException if the security manager has already - * been set and its checkPermission method + * @throws SecurityException if the security manager has already + * been set and its {@code checkPermission} method * doesn't allow it to be replaced. * @see #getSecurityManager * @see SecurityManager#checkPermission @@ -363,7 +362,7 @@ public final class System { * * @return if a security manager has already been established for the * current application, then that security manager is returned; - * otherwise, null is returned. + * otherwise, {@code null} is returned. * @see #setSecurityManager */ public static SecurityManager getSecurityManager() { @@ -378,7 +377,7 @@ public final class System { * operating systems measure time in units of tens of * milliseconds. * - *

See the description of the class Date for + *

See the description of the class {@code Date} for * a discussion of slight discrepancies that may arise between * "computer time" and coordinated universal time (UTC). * @@ -393,7 +392,7 @@ public final class System { * Returns the current value of the running Java Virtual Machine's * high-resolution time source, in nanoseconds. * - *

This method can only be used to measure elapsed time and is + * This method can only be used to measure elapsed time and is * not related to any other notion of system or wall-clock time. * The value returned represents nanoseconds since some fixed but * arbitrary origin time (perhaps in the future, so values @@ -437,76 +436,76 @@ public final class System { * Copies an array from the specified source array, beginning at the * specified position, to the specified position of the destination array. * A subsequence of array components are copied from the source - * array referenced by src to the destination array - * referenced by dest. The number of components copied is - * equal to the length argument. The components at - * positions srcPos through - * srcPos+length-1 in the source array are copied into - * positions destPos through - * destPos+length-1, respectively, of the destination + * array referenced by {@code src} to the destination array + * referenced by {@code dest}. The number of components copied is + * equal to the {@code length} argument. The components at + * positions {@code srcPos} through + * {@code srcPos+length-1} in the source array are copied into + * positions {@code destPos} through + * {@code destPos+length-1}, respectively, of the destination * array. *

- * If the src and dest arguments refer to the + * If the {@code src} and {@code dest} arguments refer to the * same array object, then the copying is performed as if the - * components at positions srcPos through - * srcPos+length-1 were first copied to a temporary - * array with length components and then the contents of + * components at positions {@code srcPos} through + * {@code srcPos+length-1} were first copied to a temporary + * array with {@code length} components and then the contents of * the temporary array were copied into positions - * destPos through destPos+length-1 of the + * {@code destPos} through {@code destPos+length-1} of the * destination array. *

- * If dest is null, then a - * NullPointerException is thrown. + * If {@code dest} is {@code null}, then a + * {@code NullPointerException} is thrown. *

- * If src is null, then a - * NullPointerException is thrown and the destination + * If {@code src} is {@code null}, then a + * {@code NullPointerException} is thrown and the destination * array is not modified. *

* Otherwise, if any of the following is true, an - * ArrayStoreException is thrown and the destination is + * {@code ArrayStoreException} is thrown and the destination is * not modified: *

*

* Otherwise, if any of the following is true, an - * IndexOutOfBoundsException is + * {@code IndexOutOfBoundsException} is * thrown and the destination is not modified: *

*

* Otherwise, if any actual component of the source array from - * position srcPos through - * srcPos+length-1 cannot be converted to the component + * position {@code srcPos} through + * {@code srcPos+length-1} cannot be converted to the component * type of the destination array by assignment conversion, an - * ArrayStoreException is thrown. In this case, let + * {@code ArrayStoreException} is thrown. In this case, let * k be the smallest nonnegative integer less than - * length such that src[srcPos+k] + * length such that {@code src[srcPos+}k{@code ]} * cannot be converted to the component type of the destination * array; when the exception is thrown, source array components from - * positions srcPos through - * srcPos+k-1 + * positions {@code srcPos} through + * {@code srcPos+}k{@code -1} * will already have been copied to destination array positions - * destPos through - * destPos+k-1 and no other + * {@code destPos} through + * {@code destPos+}k{@code -1} and no other * positions of the destination array will have been modified. * (Because of the restrictions already itemized, this * paragraph effectively applies only to the situation where both @@ -517,13 +516,13 @@ public final class System { * @param dest the destination array. * @param destPos starting position in the destination data. * @param length the number of array elements to be copied. - * @exception IndexOutOfBoundsException if copying would cause - * access of data outside array bounds. - * @exception ArrayStoreException if an element in the src - * array could not be stored into the dest array - * because of a type mismatch. - * @exception NullPointerException if either src or - * dest is null. + * @throws IndexOutOfBoundsException if copying would cause + * access of data outside array bounds. + * @throws ArrayStoreException if an element in the {@code src} + * array could not be stored into the {@code dest} array + * because of a type mismatch. + * @throws NullPointerException if either {@code src} or + * {@code dest} is {@code null}. */ @HotSpotIntrinsicCandidate public static native void arraycopy(Object src, int srcPos, @@ -574,14 +573,14 @@ public final class System { /** * Determines the current system properties. - *

+ * * First, if there is a security manager, its - * checkPropertiesAccess method is called with no + * {@code checkPropertiesAccess} method is called with no * arguments. This may result in a security exception. *

* The current set of system properties for use by the * {@link #getProperty(String)} method is returned as a - * Properties object. If there is no current set of + * {@code Properties} object. If there is no current set of * system properties, a set of system properties is first created and * initialized. This set of system properties always includes values * for the following keys: @@ -592,70 +591,70 @@ public final class System { * Description of Associated Value * * - * java.version + * {@code java.version} * Java Runtime Environment version, which may be interpreted * as a {@link Runtime.Version} - * java.version.date + * {@code java.version.date} * Java Runtime Environment version date, in ISO-8601 YYYY-MM-DD * format, which may be interpreted as a {@link * java.time.LocalDate} - * java.vendor + * {@code java.vendor} * Java Runtime Environment vendor - * java.vendor.url + * {@code java.vendor.url} * Java vendor URL - * java.vendor.version + * {@code java.vendor.version} * Java vendor version - * java.home + * {@code java.home} * Java installation directory - * java.vm.specification.version + * {@code java.vm.specification.version} * Java Virtual Machine specification version which may be * interpreted as a {@link Runtime.Version} - * java.vm.specification.vendor + * {@code java.vm.specification.vendor} * Java Virtual Machine specification vendor - * java.vm.specification.name + * {@code java.vm.specification.name} * Java Virtual Machine specification name - * java.vm.version + * {@code java.vm.version} * Java Virtual Machine implementation version which may be * interpreted as a {@link Runtime.Version} - * java.vm.vendor + * {@code java.vm.vendor} * Java Virtual Machine implementation vendor - * java.vm.name + * {@code java.vm.name} * Java Virtual Machine implementation name - * java.specification.version + * {@code java.specification.version} * Java Runtime Environment specification version which may be * interpreted as a {@link Runtime.Version} - * java.specification.vendor + * {@code java.specification.vendor} * Java Runtime Environment specification vendor - * java.specification.name + * {@code java.specification.name} * Java Runtime Environment specification name - * java.class.version + * {@code java.class.version} * Java class format version number - * java.class.path + * {@code java.class.path} * Java class path (refer to * {@link ClassLoader#getSystemClassLoader()} for details) - * java.library.path + * {@code java.library.path} * List of paths to search when loading libraries - * java.io.tmpdir + * {@code java.io.tmpdir} * Default temp file path - * java.compiler + * {@code java.compiler} * Name of JIT compiler to use - * os.name + * {@code os.name} * Operating system name - * os.arch + * {@code os.arch} * Operating system architecture - * os.version + * {@code os.version} * Operating system version - * file.separator + * {@code file.separator} * File separator ("/" on UNIX) - * path.separator + * {@code path.separator} * Path separator (":" on UNIX) - * line.separator + * {@code line.separator} * Line separator ("\n" on UNIX) - * user.name + * {@code user.name} * User's account name - * user.home + * {@code user.home} * User's home directory - * user.dir + * {@code user.dir} * User's current working directory * * @@ -664,7 +663,7 @@ public final class System { * separator character of the platform. *

* Note that even if the security manager does not permit the - * getProperties operation, it may choose to permit the + * {@code getProperties} operation, it may choose to permit the * {@link #getProperty(String)} operation. * * @implNote In addition to the standard system properties, the system @@ -688,9 +687,9 @@ public final class System { * * * @return the system properties - * @exception SecurityException if a security manager exists and its - * checkPropertiesAccess method doesn't allow access - * to the system properties. + * @throws SecurityException if a security manager exists and its + * {@code checkPropertiesAccess} method doesn't allow access + * to the system properties. * @see #setProperties * @see java.lang.SecurityException * @see java.lang.SecurityManager#checkPropertiesAccess() @@ -723,22 +722,21 @@ public final class System { private static String lineSeparator; /** - * Sets the system properties to the Properties - * argument. - *

+ * Sets the system properties to the {@code Properties} argument. + * * First, if there is a security manager, its - * checkPropertiesAccess method is called with no + * {@code checkPropertiesAccess} method is called with no * arguments. This may result in a security exception. *

* The argument becomes the current set of system properties for use * by the {@link #getProperty(String)} method. If the argument is - * null, then the current set of system properties is + * {@code null}, then the current set of system properties is * forgotten. * * @param props the new system properties. - * @exception SecurityException if a security manager exists and its - * checkPropertiesAccess method doesn't allow access - * to the system properties. + * @throws SecurityException if a security manager exists and its + * {@code checkPropertiesAccess} method doesn't allow access + * to the system properties. * @see #getProperties * @see java.util.Properties * @see java.lang.SecurityException @@ -758,25 +756,24 @@ public final class System { /** * Gets the system property indicated by the specified key. - *

+ * * First, if there is a security manager, its - * checkPropertyAccess method is called with the key as + * {@code checkPropertyAccess} method is called with the key as * its argument. This may result in a SecurityException. *

* If there is no current set of system properties, a set of system * properties is first created and initialized in the same manner as - * for the getProperties method. + * for the {@code getProperties} method. * * @param key the name of the system property. * @return the string value of the system property, - * or null if there is no property with that key. + * or {@code null} if there is no property with that key. * - * @exception SecurityException if a security manager exists and its - * checkPropertyAccess method doesn't allow - * access to the specified system property. - * @exception NullPointerException if key is - * null. - * @exception IllegalArgumentException if key is empty. + * @throws SecurityException if a security manager exists and its + * {@code checkPropertyAccess} method doesn't allow + * access to the specified system property. + * @throws NullPointerException if {@code key} is {@code null}. + * @throws IllegalArgumentException if {@code key} is empty. * @see #setProperty * @see java.lang.SecurityException * @see java.lang.SecurityManager#checkPropertyAccess(java.lang.String) @@ -794,26 +791,25 @@ public final class System { /** * Gets the system property indicated by the specified key. - *

+ * * First, if there is a security manager, its - * checkPropertyAccess method is called with the - * key as its argument. + * {@code checkPropertyAccess} method is called with the + * {@code key} as its argument. *

* If there is no current set of system properties, a set of system * properties is first created and initialized in the same manner as - * for the getProperties method. + * for the {@code getProperties} method. * * @param key the name of the system property. * @param def a default value. * @return the string value of the system property, * or the default value if there is no property with that key. * - * @exception SecurityException if a security manager exists and its - * checkPropertyAccess method doesn't allow + * @throws SecurityException if a security manager exists and its + * {@code checkPropertyAccess} method doesn't allow * access to the specified system property. - * @exception NullPointerException if key is - * null. - * @exception IllegalArgumentException if key is empty. + * @throws NullPointerException if {@code key} is {@code null}. + * @throws IllegalArgumentException if {@code key} is empty. * @see #setProperty * @see java.lang.SecurityManager#checkPropertyAccess(java.lang.String) * @see java.lang.System#getProperties() @@ -830,10 +826,10 @@ public final class System { /** * Sets the system property indicated by the specified key. - *

+ * * First, if a security manager exists, its - * SecurityManager.checkPermission method - * is called with a PropertyPermission(key, "write") + * {@code SecurityManager.checkPermission} method + * is called with a {@code PropertyPermission(key, "write")} * permission. This may result in a SecurityException being thrown. * If no exception is thrown, the specified property is set to the given * value. @@ -841,14 +837,14 @@ public final class System { * @param key the name of the system property. * @param value the value of the system property. * @return the previous value of the system property, - * or null if it did not have one. + * or {@code null} if it did not have one. * - * @exception SecurityException if a security manager exists and its - * checkPermission method doesn't allow + * @throws SecurityException if a security manager exists and its + * {@code checkPermission} method doesn't allow * setting of the specified property. - * @exception NullPointerException if key or - * value is null. - * @exception IllegalArgumentException if key is empty. + * @throws NullPointerException if {@code key} or + * {@code value} is {@code null}. + * @throws IllegalArgumentException if {@code key} is empty. * @see #getProperty * @see java.lang.System#getProperty(java.lang.String) * @see java.lang.System#getProperty(java.lang.String, java.lang.String) @@ -869,23 +865,22 @@ public final class System { /** * Removes the system property indicated by the specified key. - *

+ * * First, if a security manager exists, its - * SecurityManager.checkPermission method - * is called with a PropertyPermission(key, "write") + * {@code SecurityManager.checkPermission} method + * is called with a {@code PropertyPermission(key, "write")} * permission. This may result in a SecurityException being thrown. * If no exception is thrown, the specified property is removed. * * @param key the name of the system property to be removed. * @return the previous string value of the system property, - * or null if there was no property with that key. + * or {@code null} if there was no property with that key. * - * @exception SecurityException if a security manager exists and its - * checkPropertyAccess method doesn't allow + * @throws SecurityException if a security manager exists and its + * {@code checkPropertyAccess} method doesn't allow * access to the specified system property. - * @exception NullPointerException if key is - * null. - * @exception IllegalArgumentException if key is empty. + * @throws NullPointerException if {@code key} is {@code null}. + * @throws IllegalArgumentException if {@code key} is empty. * @see #getProperty * @see #setProperty * @see java.util.Properties @@ -920,10 +915,10 @@ public final class System { *

If a security manager exists, its * {@link SecurityManager#checkPermission checkPermission} * method is called with a - * {@link RuntimePermission}("getenv."+name) + * {@code {@link RuntimePermission}("getenv."+name)} * permission. This may result in a {@link SecurityException} * being thrown. If no exception is thrown the value of the - * variable name is returned. + * variable {@code name} is returned. * *

System * properties and environment variables are both @@ -938,23 +933,23 @@ public final class System { * unintended side effects. It is best to use system properties * where possible. Environment variables should be used when a * global effect is desired, or when an external system interface - * requires an environment variable (such as PATH). + * requires an environment variable (such as {@code PATH}). * - *

On UNIX systems the alphabetic case of name is + *

On UNIX systems the alphabetic case of {@code name} is * typically significant, while on Microsoft Windows systems it is * typically not. For example, the expression - * System.getenv("FOO").equals(System.getenv("foo")) + * {@code System.getenv("FOO").equals(System.getenv("foo"))} * is likely to be true on Microsoft Windows. * * @param name the name of the environment variable - * @return the string value of the variable, or null + * @return the string value of the variable, or {@code null} * if the variable is not defined in the system environment - * @throws NullPointerException if name is null + * @throws NullPointerException if {@code name} is {@code null} * @throws SecurityException * if a security manager exists and its * {@link SecurityManager#checkPermission checkPermission} * method doesn't allow access to the environment variable - * name + * {@code name} * @see #getenv() * @see ProcessBuilder#environment() */ @@ -991,9 +986,8 @@ public final class System { *

If a security manager exists, its * {@link SecurityManager#checkPermission checkPermission} * method is called with a - * {@link RuntimePermission}("getenv.*") - * permission. This may result in a {@link SecurityException} being - * thrown. + * {@code {@link RuntimePermission}("getenv.*")} permission. + * This may result in a {@link SecurityException} being thrown. * *

When passing information to a Java subprocess, * system properties @@ -1021,7 +1015,7 @@ public final class System { * {@code System.Logger} instances log messages that will be * routed to the underlying logging framework the {@link System.LoggerFinder * LoggerFinder} uses. - *

+ * * {@code System.Logger} instances are typically obtained from * the {@link java.lang.System System} class, by calling * {@link java.lang.System#getLogger(java.lang.String) System.getLogger(loggerName)} @@ -1033,13 +1027,12 @@ public final class System { * @see java.lang.System.LoggerFinder * * @since 9 - * */ public interface Logger { /** * System {@linkplain Logger loggers} levels. - *

+ * * A level has a {@linkplain #getName() name} and {@linkplain * #getSeverity() severity}. * Level values are {@link #ALL}, {@link #TRACE}, {@link #DEBUG}, @@ -1199,7 +1192,7 @@ public final class System { /** * Logs a lazily supplied message. - *

+ * * If the logger is currently enabled for the given log message level * then a message is logged that is the result produced by the * given supplier function. Otherwise, the supplier is not operated on. @@ -1223,7 +1216,7 @@ public final class System { /** * Logs a message produced from the given object. - *

+ * * If the logger is currently enabled for the given log message level then * a message is logged that, by default, is the result produced from * calling toString on the given object. @@ -1269,7 +1262,7 @@ public final class System { /** * Logs a lazily supplied message associated with a given throwable. - *

+ * * If the logger is currently enabled for the given log message level * then a message is logged that is the result produced by the * given supplier function. Otherwise, the supplier is not operated on. @@ -1318,7 +1311,7 @@ public final class System { /** * Logs a localized message associated with a given throwable. - *

+ * * If the given resource bundle is non-{@code null}, the {@code msg} * string is localized using the given resource bundle. * Otherwise the {@code msg} string is not localized. @@ -1339,7 +1332,7 @@ public final class System { /** * Logs a message with resource bundle and an optional list of * parameters. - *

+ * * If the given resource bundle is non-{@code null}, the {@code format} * string is localized using the given resource bundle. * Otherwise the {@code format} string is not localized. @@ -1357,14 +1350,12 @@ public final class System { */ public void log(Level level, ResourceBundle bundle, String format, Object... params); - - } /** * The {@code LoggerFinder} service is responsible for creating, managing, * and configuring loggers to the underlying framework it uses. - *

+ * * A logger finder is a concrete implementation of this class that has a * zero-argument constructor and implements the abstract methods defined * by this class. @@ -1516,9 +1507,9 @@ public final class System { * take a {@link ResourceBundle} as parameter are redirected to one * which does - passing the given {@code bundle} for * localization. So for instance, a call to {@link - * Logger#log(Level, String) Logger.log(Level.INFO, msg)} + * Logger#log(Logger.Level, String) Logger.log(Level.INFO, msg)} * will end up as a call to {@link - * Logger#log(Level, ResourceBundle, String, Object...) + * Logger#log(Logger.Level, ResourceBundle, String, Object...) * Logger.log(Level.INFO, bundle, msg, (Object[])null)} on the wrapped * logger instance. * Note however that by default, string messages returned by {@link @@ -1702,10 +1693,10 @@ public final class System { * argument serves as a status code; by convention, a nonzero status * code indicates abnormal termination. *

- * This method calls the exit method in class - * Runtime. This method never returns normally. + * This method calls the {@code exit} method in class + * {@code Runtime}. This method never returns normally. *

- * The call System.exit(n) is effectively equivalent to + * The call {@code System.exit(n)} is effectively equivalent to * the call: *

      * Runtime.getRuntime().exit(n)
@@ -1713,7 +1704,7 @@ public final class System {
      *
      * @param      status   exit status.
      * @throws  SecurityException
-     *        if a security manager exists and its checkExit
+     *        if a security manager exists and its {@code checkExit}
      *        method doesn't allow exit with the specified status.
      * @see        java.lang.Runtime#exit(int)
      */
@@ -1723,15 +1714,15 @@ public final class System {
 
     /**
      * Runs the garbage collector.
-     * 

- * Calling the gc method suggests that the Java Virtual + * + * Calling the {@code gc} method suggests that the Java Virtual * Machine expend effort toward recycling unused objects in order to * make the memory they currently occupy available for quick reuse. * When control returns from the method call, the Java Virtual * Machine has made a best effort to reclaim space from all discarded * objects. *

- * The call System.gc() is effectively equivalent to the + * The call {@code System.gc()} is effectively equivalent to the * call: *

      * Runtime.getRuntime().gc()
@@ -1745,15 +1736,15 @@ public final class System {
 
     /**
      * Runs the finalization methods of any objects pending finalization.
-     * 

+ * * Calling this method suggests that the Java Virtual Machine expend - * effort toward running the finalize methods of objects - * that have been found to be discarded but whose finalize + * effort toward running the {@code finalize} methods of objects + * that have been found to be discarded but whose {@code finalize} * methods have not yet been run. When control returns from the * method call, the Java Virtual Machine has made a best effort to * complete all outstanding finalizations. *

- * The call System.runFinalization() is effectively + * The call {@code System.runFinalization()} is effectively * equivalent to the call: *

      * Runtime.getRuntime().runFinalization()
@@ -1783,22 +1774,21 @@ public final class System {
      * an implementation-dependent manner.
      *
      * 

- * The call System.load(name) is effectively equivalent + * The call {@code System.load(name)} is effectively equivalent * to the call: *

      * Runtime.getRuntime().load(name)
      * 
* * @param filename the file to load. - * @exception SecurityException if a security manager exists and its - * checkLink method doesn't allow + * @throws SecurityException if a security manager exists and its + * {@code checkLink} method doesn't allow * loading of the specified dynamic library - * @exception UnsatisfiedLinkError if either the filename is not an + * @throws UnsatisfiedLinkError if either the filename is not an * absolute path name, the native library is not statically * linked with the VM, or the library cannot be mapped to * a native library image by the host system. - * @exception NullPointerException if filename is - * null + * @throws NullPointerException if {@code filename} is {@code null} * @see java.lang.Runtime#load(java.lang.String) * @see java.lang.SecurityManager#checkLink(java.lang.String) */ @@ -1808,11 +1798,11 @@ public final class System { } /** - * Loads the native library specified by the libname - * argument. The libname argument must not contain any platform + * Loads the native library specified by the {@code libname} + * argument. The {@code libname} argument must not contain any platform * specific prefix, file extension or path. If a native library - * called libname is statically linked with the VM, then the - * JNI_OnLoad_libname function exported by the library is invoked. + * called {@code libname} is statically linked with the VM, then the + * JNI_OnLoad_{@code libname} function exported by the library is invoked. * See the JNI Specification * for more details. * @@ -1820,22 +1810,21 @@ public final class System { * location and mapped to a native library image in an implementation- * dependent manner. *

- * The call System.loadLibrary(name) is effectively + * The call {@code System.loadLibrary(name)} is effectively * equivalent to the call *

      * Runtime.getRuntime().loadLibrary(name)
      * 
* * @param libname the name of the library. - * @exception SecurityException if a security manager exists and its - * checkLink method doesn't allow + * @throws SecurityException if a security manager exists and its + * {@code checkLink} method doesn't allow * loading of the specified dynamic library - * @exception UnsatisfiedLinkError if either the libname argument + * @throws UnsatisfiedLinkError if either the libname argument * contains a file path, the native library is not statically * linked with the VM, or the library cannot be mapped to a * native library image by the host system. - * @exception NullPointerException if libname is - * null + * @throws NullPointerException if {@code libname} is {@code null} * @see java.lang.Runtime#loadLibrary(java.lang.String) * @see java.lang.SecurityManager#checkLink(java.lang.String) */ @@ -1850,8 +1839,7 @@ public final class System { * * @param libname the name of the library. * @return a platform-dependent native library name. - * @exception NullPointerException if libname is - * null + * @throws NullPointerException if {@code libname} is {@code null} * @see java.lang.System#loadLibrary(java.lang.String) * @see java.lang.ClassLoader#findLibrary(java.lang.String) * @since 1.2 -- cgit v1.3.1