public final class ClassLoaders extends Object
ClassLoader
.Modifier and Type | Method and Description |
---|---|
static File[] |
getBootstrapClassPath()
Returns a
File array representing the paths in the classpath of the
bootstrap ClassLoader . |
static File[] |
getClassPath()
Returns a
File array representing the paths in the classpath of the
system ClassLoader . |
static File[] |
getTestClassPath()
Returns a
File array representing the paths in the Surefire test
classpath of the current Java virtual machine. |
public static File[] getClassPath()
File
array representing the paths in the classpath of the
system ClassLoader
. The classpath is determined from the
"java.class.path"
system property.File
array representing the paths in the classpath of the
system ClassLoader
.ClassLoader.getSystemClassLoader()
public static File[] getBootstrapClassPath()
File
array representing the paths in the classpath of the
bootstrap ClassLoader
. The classpath is determined from the
"sun.boot.class.path"
system property.
Note: The "sun.boot.class.path"
property has been removed in
Java 9+.
File
array representing the paths in the classpath of the
bootstrap ClassLoader
.public static File[] getTestClassPath()
File
array representing the paths in the Surefire test
classpath of the current Java virtual machine. The classpath is determined
from the "surefire.test.class.path"
system property, which is set
by the Surefire runtime.File
array representing the paths in the Surefire test
classpath of the current Java virtual machine.Copyright © 2020 LibJ. All rights reserved.