pluginDescriptor = loadPluginDescriptor();
Class<Runtime> runtimeClass = getRuntimeClass();
Runtime runtime = null;
if (runtimeClass != null) {
try {
runtime = runtimeClass.newInstance();
} catch (Exception e) {
e.printStackTrace();
throw new IllegalPluginException(e);
}
}
File files[] = pluginDirectory.listFiles();
for (File file : files) {
boolean addToClassLoader = true;
if (file.equals(pluginJarFile))
addToClassLoader = false;
else if (runtime != null)
addToClassLoader = runtime.use(file.getName());
if (addToClassLoader) {
try {