|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sonar.core.classloaders.ClassLoadersCollection
public class ClassLoadersCollection
Encapsulates manipulations with ClassLoaders, such as creation and establishing dependencies. Current implementation based on
ClassWorld.
If we have pluginA , then all classes and resources from package and subpackages of org.sonar.plugins.pluginA.api will be visible for all other plugins even if they located in dependent library.
ClassRealm :
| Constructor Summary | |
|---|---|
ClassLoadersCollection(ClassLoader baseClassLoader)
|
|
| Method Summary | |
|---|---|
ClassLoader |
createClassLoader(String key,
Collection<URL> urls,
boolean childFirst)
Generates URLClassLoader with specified delegation model. |
void |
done()
Establishes dependencies among ClassLoaders. |
void |
extend(String baseKey,
String key,
Collection<URL> urls)
|
ClassLoader |
get(String key)
Note that this method should be called only after creation of all ClassLoaders - see done(). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ClassLoadersCollection(ClassLoader baseClassLoader)
| Method Detail |
|---|
public ClassLoader createClassLoader(String key,
Collection<URL> urls,
boolean childFirst)
key - plugin keyurls - librarieschildFirst - true, if child-first delegation model required instead of parent-first
done().
public void extend(String baseKey,
String key,
Collection<URL> urls)
public void done()
public ClassLoader get(String key)
done().
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||