Top Description Fields Constructors Methods
nonapi.io.github.classgraph.classloaderhandler

pack-priv Class EquinoxClassLoaderHandler

extends Object
implements ClassLoaderHandler
Class Inheritance
All Implemented Interfaces
nonapi.io.github.classgraph.classloaderhandler.ClassLoaderHandler
Imports
java.lang.reflect.Array, java.util.HashSet, .Set, nonapi.io.github.classgraph.classpath.ClassLoaderOrder, .ClasspathOrder, nonapi.io.github.classgraph.scanspec.ScanSpec, nonapi.io.github.classgraph.utils.LogNode

Extract classpath entries from the Eclipse Equinox ClassLoader.

Field Summary

Modifier and TypeField and Description
private static boolean
alreadyReadSystemBundles

True if system bundles have been read.

private static final String[]
FIELD_NAMES

Field names.

Constructor Summary

AccessConstructor and Description
private
EquinoxClassLoaderHandler()

Class cannot be constructed.

Method Summary

Modifier and TypeMethod and Description
private static void
addBundleFile(final Object
the bundle file
bundlefile
,
final Set<Object>
the path
path
,
final ClassLoader
the classloader
classLoader
,
final ClasspathOrder
the classpath order
classpathOrderOut
,
final ScanSpec
the scan spec
scanSpec
,
final LogNode
the log
log
)

Add the bundle file.

private static void
addClasspathEntries(final Object
the owner
owner
,
final ClassLoader
the class loader
classLoader
,
final ClasspathOrder
the classpath order out
classpathOrderOut
,
final ScanSpec
the scan spec
scanSpec
,
final LogNode
the log
log
)

Adds the classpath entries.

public static boolean

Returns:

true if this ClassLoaderHandler can handle the ClassLoader.
canHandle
(final Class<?>
the ClassLoader class or one of its superclasses.
classLoaderClass
,
final LogNode
the log
log
)

Check whether this ClassLoaderHandler can handle a given ClassLoader.

public static void
findClassLoaderOrder(final ClassLoader
the ClassLoader to find the order for.
classLoader
,
final ClassLoaderOrder
a ClassLoaderOrder object to update.
classLoaderOrder
,
final LogNode
the log
log
)

Find the ClassLoader delegation order for a ClassLoader.

public static void
findClasspathOrder(final ClassLoader
the ClassLoader to find the classpath entries order for.
classLoader
,
final ClasspathOrder
a ClasspathOrder object to update.
classpathOrder
,
final ScanSpec scanSpec, final LogNode
the log.
log
)

Find the classpath entries for the associated ClassLoader.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

alreadyReadSystemBundlesback to summary
private static boolean alreadyReadSystemBundles

True if system bundles have been read. We assume there is only one system bundle on the classpath, so this is static.

FIELD_NAMESback to summary
private static final String[] FIELD_NAMES

Field names.

Constructor Detail

EquinoxClassLoaderHandlerback to summary
private EquinoxClassLoaderHandler()

Class cannot be constructed.

Method Detail

addBundleFileback to summary
private static void addBundleFile(final Object bundlefile, final Set<Object> path, final ClassLoader classLoader, final ClasspathOrder classpathOrderOut, final ScanSpec scanSpec, final LogNode log)

Add the bundle file.

Parameters
bundlefile:Object

the bundle file

path:Set<Object>

the path

classLoader:ClassLoader

the classloader

classpathOrderOut:ClasspathOrder

the classpath order

scanSpec:ScanSpec

the scan spec

log:LogNode

the log

addClasspathEntriesback to summary
private static void addClasspathEntries(final Object owner, final ClassLoader classLoader, final ClasspathOrder classpathOrderOut, final ScanSpec scanSpec, final LogNode log)

Adds the classpath entries.

Parameters
owner:Object

the owner

classLoader:ClassLoader

the class loader

classpathOrderOut:ClasspathOrder

the classpath order out

scanSpec:ScanSpec

the scan spec

log:LogNode

the log

canHandleback to summary
public static boolean canHandle(final Class<?> classLoaderClass, final LogNode log)

Check whether this ClassLoaderHandler can handle a given ClassLoader.

Parameters
classLoaderClass:Class<?>

the ClassLoader class or one of its superclasses.

log:LogNode

the log

Returns:boolean

true if this ClassLoaderHandler can handle the ClassLoader.

findClassLoaderOrderback to summary
public static void findClassLoaderOrder(final ClassLoader classLoader, final ClassLoaderOrder classLoaderOrder, final LogNode log)

Find the ClassLoader delegation order for a ClassLoader.

Parameters
classLoader:ClassLoader

the ClassLoader to find the order for.

classLoaderOrder:ClassLoaderOrder

a ClassLoaderOrder object to update.

log:LogNode

the log

findClasspathOrderback to summary
public static void findClasspathOrder(final ClassLoader classLoader, final ClasspathOrder classpathOrder, final ScanSpec scanSpec, final LogNode log)

Find the classpath entries for the associated ClassLoader.

Parameters
classLoader:ClassLoader

the ClassLoader to find the classpath entries order for.

classpathOrder:ClasspathOrder

a ClasspathOrder object to update.

scanSpec:ScanSpec

the ScanSpec.

log:LogNode

the log.