* @param fromMe The descriptor to use for the loader
* @param collector The error collector to fill in if this returns null
* @return null on failure to load (the failure will be added to the collector)
*/
public static Class<?> loadClass(String loadMe, Descriptor fromMe, Collector collector) {
HK2Loader loader = fromMe.getLoader();
if (loader == null) {
ClassLoader cl = Utilities.class.getClassLoader();
if (cl == null) {
cl = ClassLoader.getSystemClassLoader();
}
try {
return cl.loadClass(loadMe);
} catch (Throwable th) {
collector.addThrowable(th);
return null;
}
}
try {
return loader.loadClass(loadMe);
} catch (Throwable th) {
if (th instanceof MultiException) {
MultiException me = (MultiException) th;
for (Throwable th2 : me.getErrors()) {