public static class ByteArrayClassLoader.ChildFirst extends ByteArrayClassLoader
A ByteArrayClassLoader
which applies child-first semantics for the
given type definitions.
Important: Package definitions remain their parent-first semantics as loaded package definitions do not expose their class loaders.
ByteArrayClassLoader.ChildFirst, ByteArrayClassLoader.ClassLoadingAction, ByteArrayClassLoader.PersistenceHandler
accessControlContext, packageDefinitionStrategy, persistenceHandler, protectionDomain, typeDefinitions
Constructor and Description |
---|
ChildFirst(ClassLoader parent,
Map<String,byte[]> typeDefinitions,
ProtectionDomain protectionDomain,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
PackageDefinitionStrategy packageDefinitionStrategy)
Creates a new child-first byte array class loader.
|
Modifier and Type | Method and Description |
---|---|
InputStream |
getResourceAsStream(String name) |
protected Class<?> |
loadClass(String name,
boolean resolve) |
String |
toString() |
findClass, load, of
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
public ChildFirst(ClassLoader parent, Map<String,byte[]> typeDefinitions, ProtectionDomain protectionDomain, ByteArrayClassLoader.PersistenceHandler persistenceHandler, PackageDefinitionStrategy packageDefinitionStrategy)
parent
- The ClassLoader
that is the parent of this class loader.typeDefinitions
- A map of fully qualified class names pointing to their binary representations.protectionDomain
- The protection domain to apply where null
references an implicit
protection domain.persistenceHandler
- The persistence handler of this class loader.packageDefinitionStrategy
- The package definer to be queried for package definitions.protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
loadClass
in class ClassLoader
ClassNotFoundException
public InputStream getResourceAsStream(String name)
getResourceAsStream
in class ByteArrayClassLoader
public String toString()
toString
in class ByteArrayClassLoader
Copyright © 2014–2015. All rights reserved.